Answer the question
In order to leave comments, you need to log in
How to run create react app not on root url?
Hello!
I have a site running on the root URL through a proxy on node.js.
And my admin panel is on another URL "/manager" and is made on CRA.
The problem is that on such a URL, the non-build version does not start at all, I already tried to specify "homepage" but something does not work.
{
"homepage": "/manager"
"name": "manager",
"version": "0.1.0",
"private": true,
"dependencies": {
"@material-ui/core": "^4.3.1",
"@material-ui/icons": "^4.2.1",
"apollo-boost": "^0.4.3",
"graphql": "^14.4.2",
"react": "^16.8.6",
"react-apollo": "^2.5.8",
"react-dom": "^16.8.6",
"react-scripts": "3.0.1",
"react-swipeable-views": "^0.13.3",
"recompose": "^0.30.0"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question