mirror of
https://github.com/karma-riuk/crab-webapp.git
synced 2025-07-06 06:28:12 +02:00
created basic backend, with simple routes
This commit is contained in:
14
src/routes/index.js
Normal file
14
src/routes/index.js
Normal file
@ -0,0 +1,14 @@
|
||||
const express = require('express');
|
||||
const router = express.Router();
|
||||
|
||||
// Routes
|
||||
router.get('/', (req, res) => {
|
||||
res.json({ message: 'Welcome to the Express backend!' });
|
||||
});
|
||||
|
||||
// Example route
|
||||
router.get('/api/hello', (req, res) => {
|
||||
res.json({ message: 'Hello from the backend!' });
|
||||
});
|
||||
|
||||
module.exports = router;
|
Reference in New Issue
Block a user