A couple of weeks ago I asked about reprocessing in a Rescript/React program. I’ve now made enough progress that I feel as if I’m pretty close. But my problem here is with build processes that I don’t understand, so following earlier advice, I’m making code available. What I’ve done is available here.
The ReProcessing part of the program (when run on its own, without React stuff) produces something like this:
(the red and blue part, not the pale-blue surround).
If you look at public/index.html, you can see that I’ve tried to include the ReProcessing program (Square.res
, which becomes Square.bs.js
) as a script, followed by a div
called root
so that the usual react-starter-app can appear below my canvas.That process alone took a long time, because I haven’t developed anything for the web since the days of static web pages! The stock react-demo works fine; the reprocessing part shows nothing.
Changing the .js
file included by the first script command seems to have no effect, although I tried various paths, and even main.js
, in hopes that the webpack thing I did might produce that.
The webpack.config.js
is my crude attempt to mimic something I found in another repo, and it didn’t work.
I’m hoping this is the sort of thing where an expert will look, laugh briefly at my ignorance, say “get rid of the webpack config file, and change line 38 of your public/index.html
file to something-or-other and you’ll be on your way.” I sure hope so, because after 12 hours of trying things, I’m getting a bit frustrated.