hyeyeon-sun

server build

1 +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2 +
3 +# dependencies
4 +/node_modules
5 +/.pnp
6 +.pnp.js
7 +
8 +# testing
9 +/coverage
10 +
11 +# production
12 +/build
13 +
14 +# misc
15 +.DS_Store
16 +.env.local
17 +.env.development.local
18 +.env.test.local
19 +.env.production.local
20 +
21 +npm-debug.log*
22 +yarn-debug.log*
23 +yarn-error.log*
1 +{
2 + "name": "management",
3 + "version": "0.1.0",
4 + "private": true,
5 + "dependencies": {
6 + "@material-ui/core": "^4.10.2",
7 + "@testing-library/jest-dom": "^4.2.4",
8 + "@testing-library/react": "^9.5.0",
9 + "@testing-library/user-event": "^7.2.1",
10 + "react": "^16.13.1",
11 + "react-dom": "^16.13.1",
12 + "react-scripts": "3.4.1"
13 + },
14 + "scripts": {
15 + "start": "react-scripts start",
16 + "build": "react-scripts build",
17 + "test": "react-scripts test",
18 + "eject": "react-scripts eject"
19 + },
20 + "eslintConfig": {
21 + "extends": "react-app"
22 + },
23 + "browserslist": {
24 + "production": [
25 + ">0.2%",
26 + "not dead",
27 + "not op_mini all"
28 + ],
29 + "development": [
30 + "last 1 chrome version",
31 + "last 1 firefox version",
32 + "last 1 safari version"
33 + ]
34 + }
35 +}
1 -{
2 - "name": "management",
3 - "version": "0.1.0",
4 - "private": true,
5 - "dependencies": {
6 - "@material-ui/core": "^4.10.2",
7 - "@testing-library/jest-dom": "^4.2.4",
8 - "@testing-library/react": "^9.5.0",
9 - "@testing-library/user-event": "^7.2.1",
10 - "react": "^16.13.1",
11 - "react-dom": "^16.13.1",
12 - "react-scripts": "3.4.1"
13 - },
14 - "scripts": {
15 - "start": "react-scripts start",
16 - "build": "react-scripts build",
17 - "test": "react-scripts test",
18 - "eject": "react-scripts eject"
19 - },
20 - "eslintConfig": {
21 - "extends": "react-app"
22 - },
23 - "browserslist": {
24 - "production": [
25 - ">0.2%",
26 - "not dead",
27 - "not op_mini all"
28 - ],
29 - "development": [
30 - "last 1 chrome version",
31 - "last 1 firefox version",
32 - "last 1 safari version"
33 - ]
34 - }
35 -}
1 +const express = require('express');
2 +const bodyParser = require('body-parser');
3 +const app = express();
4 +const port = process.env.PORT || 5000;
5 +
6 +app.use(bodyParser.json());
7 +app.use(bodyParser.urlencoded({ exrended : true }));
8 +
9 +//api의 hello라는 경로로 들어갔을때의 처리
10 +app.get('/api/hello', (req,res)=>{
11 + res.send({message: 'Hello Express!'});
12 +})
13 +
14 +app.listen(port, () => console.log(`Listening on port ${port}`));
...\ No newline at end of file ...\ No newline at end of file