-
Notifications
You must be signed in to change notification settings - Fork 455
Closed
Description
I want to use different js_of_ocaml flags in my project, depending on whether we are in dev or release profile.
Dune already adds --pretty and --source-maps-inline in dev, however, there are more jsoo options to play with, and I get dramatically better debugging with the recommended settings:
For Debugging: "–pretty –no-inline –debug-info" + eventually "–disable staticeval –disable share"
For Production: "–opt 3". It minimize the generated javascript by applying various optimizations until a fix-point is reached
I tried using an env block, but couldn't make it work any way I tried it. Is there an existing way to do this, and if not:
- can a way to do this be added?
- can we pick better defaults for the dev and production env?
Mbodin, Lupus, joprice, frou and toastal