Reputation: 345
I'm building a web app with the frontend done in react, and I was wondering if it's possible to compile my react code into static HTML and JS files to be used with any server. So far I've been using the server run with
npm start
but for my final project I need to use a different one.
Upvotes: 2
Views: 1663
Reputation: 121
npm run build
This command creates a built version of your application in the build folder
Upvotes: 4
Reputation: 15821
Static builds are a standard in react deploying pipelines. You have to setup a build pipeline with webpack configuring it for minification assets management and so on.
Upvotes: 0