Skip to content

Commit 3c84b21

Browse files
authored
Update README.md
Added ´type="module"´ to fix "Cannot use import statement outside a module" error.
1 parent 6f006ee commit 3c84b21

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ You may also consider using [`plotly.js-dist`](https://www.npmjs.com/package/plo
7171

7272
Alternatively you may consider using [native ES6 import](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules) in the script tag.
7373
```html
74-
<script>
74+
<script type="module">
7575
import "https://cdn.plot.ly/plotly-2.2.0.min.js"
7676
Plotly.newPlot("gd", [{ y: [1, 2, 3] }])
7777
</script>

0 commit comments

Comments
 (0)