Open stasberkov opened 8 years ago
@ldez Once Opal is loaded an extension is just a JavaScript file to include. Do you know if it's possible to load JavaScript files from the package settings ?
@Mogztter it's possible to load script on demand but I don't know if we can execute external scripts. Possible security issues but we can use a dedicated package.
If you can provide an example I can try quickly.
@ldez you can try to execute the emoji extension: https://github.com/asciidoctor/asciidoctor-chrome-extension/blob/master/app/js/vendor/asciidoctor-emoji-inline-macro.js
You will also need this stylesheet: https://github.com/asciidoctor/asciidoctor-chrome-extension/blob/master/app/css/twemoji-awesome.css
In your document add emoji:heart[lg]
asciidoctor.js has numerous extensions. Allow loading them in preview as well (e.g. setting extensions via package settings).