- I am trying to deploy react application in netlify as referred from the medium link: https://link.medium.com/nw9ZCh0lrV
- so I used express server to define build scripts and setting application in production mode
- Build scripts are creating in local machine and uploaded in netlify site
- It shows message as successful deployment
- on clicking on URL link, it shows status to GET request for build scripts as 404
- netlify URL link: https://nostalgic-euclid-4f95ab.netlify.com
- can you guys help me where I have done mistake with your suggestion
- attached application screenshots below -providing code snippets below:
server.js
const express = require('express');
const favicon = require('express-favicon');
const app = express();
app.use(favicon(__dirname + '/build/favicon.ico'));
app.use(express.static(__dirname));
app.use(express.static(path.join(__dirname,'build')));
app.get('/*', function (req, res) {
res.sendFile(path.join(__dirname, 'build', 'index.html'));
});
packagae.json
"scripts" : {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
}

