-
I understand we can implement IGlobalMethodProvider, but are we able to add libraries to the scripting engine? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Do you mean like full JS libraries? @sebastienros? This might be a good question for Jint, since that's what OC uses under the hood. |
Beta Was this translation helpful? Give feedback.
-
@weirdyang it is not perfect, but as a workaround you can place extarnal JS lib content before your script:
|
Beta Was this translation helpful? Give feedback.
-
@weirdyang another idea is to just change a bit "createScope" method and add a way to register external modules: here I've just hardcoded two dummy modules, just to make sure it works: |
Beta Was this translation helpful? Give feedback.
@weirdyang another idea is to just change a bit "createScope" method and add a way to register external modules:
here I've just hardcoded two dummy modules, just to make sure it works:
example: