diff options
author | bptato <nincsnevem662@gmail.com> | 2023-06-19 18:13:10 +0200 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2023-06-19 18:15:09 +0200 |
commit | 17097052794aef56bbc55327d3e6c84ae1c67378 (patch) | |
tree | 13b81e1105c07c69d7a8d1e7367a698f41663a01 /src/html | |
parent | e372bdaa0344b23c91aefa4da44c578fbf8f49e2 (diff) | |
download | chawan-17097052794aef56bbc55327d3e6c84ae1c67378.tar.gz |
Rework JS exception system
Now we use Result for passing exceptions to JS. As a result, we can finally get rid of the .jserr pragma.
Diffstat (limited to 'src/html')
-rw-r--r-- | src/html/env.nim | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/html/env.nim b/src/html/env.nim index 5883dabf..a70508be 100644 --- a/src/html/env.nim +++ b/src/html/env.nim @@ -8,6 +8,7 @@ import io/promise import io/request import io/response import io/window +import js/exception import js/intl import js/javascript import js/timeout @@ -112,6 +113,7 @@ proc addScripting*(window: Window, selector: Selector[int]) = ctx.setOpaque(global, window) ctx.defineProperty(global, "window", global) JS_FreeValue(ctx, global) + ctx.addDOMExceptionModule() ctx.addconsoleModule() ctx.addNavigatorModule() ctx.addDOMModule() |