12 lines
No EOL
403 B
TypeScript
12 lines
No EOL
403 B
TypeScript
import express from 'express';
|
|
import { authenticateToken } from '../middlewares/checkAuth.test';
|
|
import { createProduct, listProducts, getProduct } from '../controllers/ProductController.test';
|
|
|
|
const productRouter = express.Router();
|
|
|
|
productRouter.post('/', authenticateToken, createProduct)
|
|
productRouter.get('/', listProducts);
|
|
productRouter.get('/:id', getProduct);
|
|
|
|
|
|
export default productRouter; |