Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
// Dependencies
var express = require('express');
var router = express.Router();
var Product = require('../models/product');
Product.methods(['get', 'put', 'post', 'delete']);
Product.register(router, '/products');
// Return router
module.exports = router;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment