Deploying a Reactjs application (CRA) on heroku throws an error - reactjs

Following is the error I am getting. The front-end of the application is built using CRA. And the backend is built with Laravel - Laravel Sanctum and Laravel Fortify. I am using craco for building the app.
Error: React Refresh runtime should not be included in the production bundle.

I found the issue. Heroku was building the react app using nodejs buildpack. In order to deploy a react project scaffolded using create-react-app a buildpack other than "heroku/nodejs" needs to be used. In my case I used this buildpack -> https://github.com/mars/create-react-app-buildpack.git. And finally using this I got the app to working.
Thank you #mando for you help.

Related

How to deploy a React js .Net Core app in git repository in heroku

I'm using heroku for the first time!
I created a React js .Net Core app in visual studio (with the repository on git), but when I try to deploy it in heroku, this error appears:
I have this buildpacks too:
UPDATE:
Also tried buildpacks like this:
but shows this error:
Note:
With a normal React app it works, but I can't with React .Net Core
Can someone help me?

Heroku deploy backend Nestjs + React js as frontend build not succeeding

After hours of reading this tricky build for Heroku using nestjs as backend and reactjs as frontend separately with MySQL still react app does not succeed building into heroku, failing "react-scripts: not found" which I have copy from the devdependencies to dependencies.
I would like some suggestions/guidance on the clear steps from the react part setup to make the build successful with nestjs (separately).

Stopping Heroku from building a react app, and deploying with local production build

I want to deploy a React + Django application on Heroku. When I push to Heroku, it automatically rebuilds my application without referring to my webpack. Is there any way I can push my build directory directly to Heroku?
Thanks!

AngularJS deployment to Netlify

I have a complete project of angularJS app with backend in nodeJS. I want to deploy it to netlify with complete frontend and backend.
My app starts in commandline with "npm start" and in browser "localhost:8081".
Can I deploy it to netlify. Is it possible?
If yes then please help me regarding this issue.
You can't expose your NodeJS API through Netlify, but you can deploy your AngularJS front-end.
Follow this link to do that Hosting Angular Apps on Netlify

React app using webpack to be deployed on JBOSS

Any idea how to deploy a React app or angular app to JBOSS webserver ?
I was working on a POC project using React and webpack-dev-server and now I have a bundle.js. Is it possible to deploy the bundle.js under a JBOSS directory (webapp.war)
Or will I need somehow run my react application on a separate server and port using npm/node/express and then somehow redirect JBOSS requests to this url ?
Please help.

Resources