changed location of static files and port
This commit is contained in:
parent
6b2f5c5362
commit
8444c7ab44
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,5 +1,6 @@
|
||||
.now
|
||||
node_modules
|
||||
build
|
||||
|
||||
# Environment Variables
|
||||
.env
|
||||
|
@ -5,12 +5,14 @@ const upload = require('./upload/index');
|
||||
const save = require('./save/index');
|
||||
const file = require('./file/index');
|
||||
const bodyParser = require('body-parser');
|
||||
const port = 5000;
|
||||
const port = 50001;
|
||||
|
||||
app.use(bodyParser.urlencoded({ extended: true }));
|
||||
app.use(bodyParser.json());
|
||||
|
||||
app.use(express.static('public'));
|
||||
// app.use(express.static('public'));
|
||||
//serve static files from build folder instead of public folder
|
||||
app.use('/', express.static('build'));
|
||||
|
||||
app.use('/api/data', data);
|
||||
app.use('/api/upload', upload);
|
||||
|
Loading…
Reference in New Issue
Block a user