Closed jschyra closed 5 months ago
Hi @jschyra, BROWSER=none is only react specific and does not work in other frameworks like vue or vanilajs, passing the env variable to all the frameworks may cause the command to fail. I have already created a PR in neutralinojs-react starter template to fix this (#8)
Hi @viralgupta, thank you for the clarification! I hadn't really considered that. I will close the pull request.
Thanks also for opening the PR on the template project!
This feature adds a configuration variable that can be used to pass the
BROWSER=none
environment variable to thedevCommand
directly from the code. The prefix can thus be shortened from the command. This supports the cross-platform compatibility of a project without the need to use external libraries such ascross-env
. As the process environment for thedevCommand
is copied and then modified, global variables are still permitted and the current environment of the process is not affected. The feature is also backwards compatible, as a process does not mind that the same variable is set twice.The behavior of the variable is:
cli.frontendLibrary.dontStartBrowser = unavailable => BROWSER=none will be added to the devCommand call
cli.frontendLibrary.dontStartBrowser = true => BROWSER=none will be added to the devCommand call
cli.frontendLibrary.dontStartBrowser = false => nothing will be added to the devCommand call