---
title: "Discussion on \"Fixing \"Cannot use import statement outside a module\" in Svelte PopperJs\" | Hashnode"
description: "Discussion on \"Fixing \"Cannot use import statement outside a module\" in Svelte PopperJs\". Fix \"Cannot use import statement outside a module\" error in Svelte with PopperJs: modify `package.json` to include `\"type\": \"module\"`"
url: "https://hashnode.com/posts/cannot-import-statement-outside-module-svelte-popperjs/66a97b0565aae4b45522008c"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Fixing "Cannot use import statement outside a module" in Svelte PopperJs](https://blog.makeinfo.co/cannot-import-statement-outside-module-svelte-popperjs?utm_source=hashnode&utm_medium=feed)

Fix "Cannot use import statement outside a module" error in Svelte with PopperJs: modify \`package.json\` to include \`"type": "module"\`

Jul 30, 2024 · 2 min read · blog.makeinfo.co  
Read the article

-   [#popperjs](https://hashnode.com/tag/popperjs)
-   [#svelte](https://hashnode.com/tag/svelte)
-   [#sveltekit](https://hashnode.com/tag/sveltekit)
-   [#troubleshooting](https://hashnode.com/tag/troubleshooting)
-   [#programming-blogs](https://hashnode.com/tag/programming-blogs)

## Written by

[Dorothi Viki](https://hashnode.com/@makeinfo)

@makeinfo · Toronto, Canada

  
[View profile](https://hashnode.com/@makeinfo)

Productivity with few clicks

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
