-
-
Notifications
You must be signed in to change notification settings - Fork 227
Open
Description
If I just add this code, it gives the error "Cannot use import statement outside a module"
What am I doing wrong?
See the code here: https://jsfiddle.net/4gvwatLn/
<script type="module" src="https://unpkg.com/rough-notation?module"></script>
<script>
import { annotate } from 'rough-notation';
// Or using unpkg
// import { annotate } from 'https://unpkg.com/rough-notation?module';
const e = document.querySelector('#myElement');
const annotation = annotate(e, { type: 'underline' });
annotation.show();
</script>
benwoodward
Metadata
Metadata
Assignees
Labels
No labels