AngleSharp / AngleSharp.Js

:angel: Extends AngleSharp with a .NET-based JavaScript engine.
https://anglesharp.github.io
MIT License
103 stars 22 forks source link

Added extra logic so lexical environments are also cached and tied to… #2

Closed miroslav22 closed 9 years ago

miroslav22 commented 9 years ago

… a specific IWindow instance. Allows scripts to access functions defined outside of their own scope but in the same context.

FlorianRappl commented 9 years ago

The ScriptingService seems to lacking to get the "current" JavaScriptEngine. Unfortunately it will always create a new instance. So even though the changes in the JS engine may be suitable, the overall construct is unfortunately not. I am the one to blame here, I guess :(.

FlorianRappl commented 9 years ago

I think the whole locking thing can be omitted safely. AngleSharp should take care to only run one script at a time. In fact it should all be handled by the event loop.