score:1
Could you show your dependencies in the package.json
file?
I had a similar problem running gcloud app deploy
Error: Cannot find module 'webpack-dev-server'
at Function.Module._resolveFilename (module.js:469:15)
I solved the issue moving the given dependency (wepack-dev-server) from devDependencies
to dependencies
in package.json.
In case somebody else has the same problem I suggest to have look at your dependencies
in package.json. dependencies
are required to run, devDependencies
only to develop, e.g.: unit tests, Coffeescript to Javascript transpilation, minification,
score:2
You need to change your scripts. Installing Webpack globally in App Engine is not the best approach, use it directly from node_modules
.
First, ensure webpack is in your production dependencies:
npm install --save webpack
Edit your package.json
script:
"scripts": {
"start": "node server.js",
"bundle": "./node_modules/.bin/webpack --config webpack.config.js",
"prestart": "npm run bundle"
},
Now a plain npm install
in a clean installation will be enough for bundling your application.
Source: stackoverflow.com
Related Query
- Cannot deploy my reactjs webpack application on google app engine
- ReactJS deploy app error Cannot copy to clipboard: Command failed: xsel --clipboard --input
- Deploy create-react-app on Google App Engine
- My react frontend is not changing when I deploy to Google App Engine
- How Do I Deploy Flask API & React Frontend Microservices to Google App Engine with Proxy?
- Deploy create-react-app-typescript on Google App Engine
- Cannot deploy Nextjs application on app service using Azure Pipleline
- webpack cannot resolve folders in reactjs app on deployment
- Deploy Next.JS web-app that used Yarn to Google App Engine
- Share codebase using common Sdk module in create react app Reactjs application
- caching issue with web application developed using reactjs & webpack
- Can I deploy my ReactJS app on a regular host?
- Webpack 5 Errors - Cannot Resolve 'crypto', 'http', and 'https' in ReactJS Project
- how to deploy reactJS application on Tomcat Server
- Deploying app to google app engine and want to start api and client
- google app engine with React and Node: Production setup
- How to deploy a reactJS application to Heroku
- How do I deploy a React Webpack web app to Azure App Service?
- Unable to deploy React JS application on Azure App service
- Google Cloud Bucket and ReactJS app Access
- Trying to deploy my REACT Webpack app to heroku. Everything works locally and the heroku build works. But I'm getting a 404 nginx
- cannot load html from webpack loader in reactjs
- Module not found: Error: Cannot resolve module 'components/app'. webpack + reactjs issue
- Not Sure How to Start and Deploy ReactJS App on Production Server with ExpressJS
- How to deploy ReactJS web application on a windows server using Node.JS?
- Google App Engine, index.html cached after deploy in express/react app
- How to deploy reactJS app with json-server
- Deploying DjangoREST+React project on a single google cloud app engine instance. Is it possible?
- Cannot create a new reactJs application
- Reactjs web app google maps working on PC localhost but not on mobile
More Query from same tag
- Handle cell click state on React.js
- React router two URL parameters &more
- ModalTrigger not found but the Modal component is?
- Recat Hooks how to detect a change if state is 0
- css-loader localIdentName: is a hash necessary for uniqueness?
- React close modal on click outside
- Confused on service worker with NextJS & Express
- react dropdown using ref and select tag
- Add item to property with an array value in specialized component
- react on rails / react intl
- Can't include pagination with React in API request
- Apply Multiple filter in redux action
- Why are my notes not displayed/updated, even though reactjs received the data?
- React Hot Reload with Redux
- Problem with deploying a MERN app on Heroku with MongoDB Atlas
- React: Create a new html element on click
- How to disable the button in vue?
- How to run a landing page with one section using ReactJS?
- Cannot save data returned from fetch on a functional component
- React hook unit test
- How to render PDF in react?
- How do I apply a URL in a string?
- React Application Unit Testing
- How is it that binding a method inside the constructor is different from binding it inside the call to React.cloneElement?
- HTML canvas not drawing image
- How to register event with useEffect hooks?
- error in importing css class to react component
- Can't access to Object Value
- deleting data from react-table
- React.Component 'this' changed in ComponentDidMount