That is good to know.
The nature of the application is such that they are not likely to mess up the global environment but if they do, we can tell them not to do that. The app won't have wide distribution - it will only be used people who work with me and a few select customers.
I like the idea of wrapping in an anonymous function with strict mode but I'll need to see how that impacts the rest of the application and it's interaction with the Host. In general, I think if I just document the behaviour you described that should be sufficient. The user will have the option to reload a clean environment or keep editing the existing environment. I'll give them something like a
Thanks for your answer.
The nature of the application is such that they are not likely to mess up the global environment but if they do, we can tell them not to do that. The app won't have wide distribution - it will only be used people who work with me and a few select customers.
I like the idea of wrapping in an anonymous function with strict mode but I'll need to see how that impacts the rest of the application and it's interaction with the Host. In general, I think if I just document the behaviour you described that should be sufficient. The user will have the option to reload a clean environment or keep editing the existing environment. I'll give them something like a
Reload
button that will recreate a new clean script engine and reload everthing including their latest user script. They can choose to Run
their dirty script or Reload
a clean script.Thanks for your answer.