GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com β€” GitHub - CapSubham/SAP-Build-Code

BranchesTags
Open more actions menu

Latest commit

 

History

6 Commits
6 Commits

Folders and files

NameName
Last commit message
Last commit date
.env
.env
 
 
.gitignore
.gitignore
 
 
App.jsx
App.jsx
 
 
README.md
README.md
 
 
TaskForm.jsx
TaskForm.jsx
 
 
TaskList.jsx
TaskList.jsx
 
 
api.js
api.js
 
 
db.js
db.js
 
 
index.html
index.html
 
 
index.js
index.js
 
 
main.jsx
main.jsx
 
 
package.json
package.json
 
 
tasks.js
tasks.js
 
 
vite.config.js
vite.config.js
 
 

Repository files navigation

Full-Stack Node.js CRUD (SAP Build Code friendly)

A minimal full‑stack app using Express (Node.js) + SQLite backend and React (Vite) frontend. It implements CRUD for a simple Task entity.

Works great locally, in VS Code, and in SAP Business Application Studio (Dev Space: Node.js / Full-Stack). You can also deploy the server to SAP BTP (Cloud Foundry) and serve the built React app from the same process.


πŸ“¦ Project structure

node-crud-fullstack-sap-build/
β”œβ”€ server/                # Express + SQLite API
β”‚  β”œβ”€ src/
β”‚  β”‚  β”œβ”€ index.js         # App entry, mounts /api/tasks
β”‚  β”‚  └─ routes/tasks.js  # CRUD routes
β”‚  β”œβ”€ src/db.js           # SQLite init
β”‚  β”œβ”€ package.json
β”‚  └─ .env                # PORT=4000
└─ client/                # React + Vite UI
   β”œβ”€ src/
   β”‚  β”œβ”€ components/
   β”‚  β”‚  β”œβ”€ TaskForm.jsx
   β”‚  β”‚  └─ TaskList.jsx
   β”‚  β”œβ”€ App.jsx
   β”‚  β”œβ”€ api.js
   β”‚  └─ main.jsx
   β”œβ”€ index.html
   β”œβ”€ vite.config.js
   └─ package.json

πŸƒβ€β™‚οΈ Run locally (two terminals)

Terminal A – API

cd server
npm install
npm run dev   # starts http://localhost:4000

Terminal B – Frontend

cd client
npm install
npm run dev   # opens http://localhost:5173, proxy to /api

πŸ§ͺ Test API quickly

After starting the server, try:

curl -X POST http://localhost:4000/api/tasks        -H 'Content-Type: application/json'        -d '{"title":"First task","description":"Hello"}'

curl http://localhost:4000/api/tasks

πŸ—οΈ Build for production

# Build static frontend
cd client && npm install && npm run build

# Start server in production mode (serves client/dist)
cd ../server
NODE_ENV=production npm start
# Open http://localhost:4000

🧰 Use in SAP Business Application Studio

  1. Create a Node.js dev space.
  2. Upload or clone this project.
  3. Open two terminals and follow the local run steps above.
  4. Optional: configure a Cloud Foundry target and push the server with a manifest.yml (bind to a SQLite-compatible persistent storage or migrate to SAP HANA Cloud / PostgreSQL). Frontend build can be served by the same Express app.

πŸ”Œ API surface

  • GET /api/tasks – list tasks
  • GET /api/tasks/:id – fetch one
  • POST /api/tasks – create { title, description?, status? }
  • PUT /api/tasks/:id – update any of { title, description, status }
  • DELETE /api/tasks/:id – remove

πŸ“„ License

MIT β€” use freely.

About

No description, website, or topics provided.

Resources

Readme
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402775 β€” GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800Γ—600. No cookies required.