forked from the-api-administration/coding-resources-api
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathserver.js
More file actions
25 lines (22 loc) Β· 631 Bytes
/
server.js
File metadata and controls
25 lines (22 loc) Β· 631 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
const express = require('express');
const app = express();
const cors = require('cors');
const PORT = process.env.PORT || 8000;
app.use(cors());
const resources = [
{
name: 'Oh Shit, Git!',
url: 'https://ohshitgit.com/',
tags: ['git', 'version control', 'command line'],
},
{
name: 'Javascript.info - Arrays',
url: 'https://javascript.info/array',
tags: ['arrays'],
},
];
app.listen(PORT, () => {
console.log(
`The π¨βπ server π is πββοΈ running π‘ on β port πΉ ${PORT}, π better π
go π catch π it! π`,
);
});