Properly document browser-env options


There are a number of browser-env options that work only partially or not at all:

  • :optimizations - Only :whitespace and :simple appear to work for me

  • :host - Is never read. Instead, we always bind to

  • :serve-static - Is never read.

  • reloaded-libs - Is never read.

These should either be properly documented, removed, or made to work.




Mike Fikes
March 15, 2018, 1:26 AM

Patch no longer applies. Perhaps obsolete now given David's last comment?

David Nolen
February 26, 2018, 11:51 PM

I ended up doing the optimizations removal as well as making host work as part of exposing that functionality to cljs.main.

David Nolen
February 26, 2018, 6:20 PM

Let's remove the optimizations bit, it's only for the client JS.

David Nolen
July 8, 2017, 4:48 PM

Related CLJS-1502

Timothy Pote
July 5, 2017, 2:43 PM

After thinking about it some more, I'm not sure what the gain is for being able to specify :optimizations in the browser-env, and the cost is confusion on the part of the users. I do not think it's apparent that this is a compiler option for the child iframe JS and evaluated repl forms. This may be a case where we can just "do the right thing" and remove some burden from the user.

I'm thinking we either remove :optimizations entirely or we only use it for evaluated repl forms and use :simple for the initial payload. Considering the user can already override this in the arguments to cljs.repl/repl, I lean toward removing it altogether.


Timothy Pote


Timothy Pote