Acode
Acode copied to clipboard
Allow using 'import' in plugins
Line 10;
Add 'type="module"' to the script tag so plugins can import external files that using just one file. /
Line 10;
Add 'type="module"' to the script tag so plugins can import external files that using just one file. /
What do you mean by that? Make the plugin in es6?
Right now, if the plugin has extra dependencies, you have use bundle it into just one js file using something like browserify, but using modules allows you to use import statement, thereby removing the need for bundling, at least for local files.
Right now, if the plugin has extra dependencies, you have use bundle it into just one js file using something like browserify, but using modules allows you to use import statement, thereby removing the need for bundling, at least for local files.
Just import that dependency through script tag.