/*index.js*/
const express = require( 'express' );
const cors = require( 'cors' );
const app = express(); const port = 3030;
//cors is enabled through out the entire app
app.use( cors() );
app.get( '/users', (request, response, next) => { res.json( { info: 'cors is enabled' } ) });
app.listen( port, () => {
console.log(`App is running on ${port}`)
});