The below code will run a Webpack watch while leveraging create-react-app
and react-app-rewired. The code is primarily based off of
this gist but modified to work with react-app-rewired
.
Some of the comments on the original gist helped make this work.
Having a watch task like this is useful when you need to use your create-react-app
-scaffolded code run through another
server and not the Webpack dev server.