Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SyntaxError: Cannot use import statement outside a module #1329

Closed
3 tasks done
yeojongki opened this issue Sep 13, 2022 · 1 comment
Closed
3 tasks done

SyntaxError: Cannot use import statement outside a module #1329

yeojongki opened this issue Sep 13, 2022 · 1 comment
Labels
bug: pending triage Maybe a bug, waiting for confirmation

Comments

@yeojongki
Copy link

Describe the bug

An error occurred while building with [email protected] ([email protected]) and ant-design-vue (dev working!)

SyntaxError: Cannot use import statement outside a module

image

Reproduction

Steps:

  1. create a new project
  2. register a custom component custom-button
  3. use the custom-button in index.md
  4. building with vitepress

Reproduction repo:
https://github.com/yeojongki/vitepress-cannot-use-import-statement-outside-a-module (cd docs && pnpm i && pnpm build)

Expected behavior

success build

System Info

System:
    OS: Windows 10 10.0.19044
    CPU: (8) x64 Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz
    Memory: 12.70 GB / 31.97 GB
  Binaries:
    Node: 16.13.0 - E:\nodejs\node.EXE
    Yarn: 1.22.17 - E:\nodejs\yarn.CMD
    npm: 8.1.3 - E:\nodejs\npm.CMD
  Browsers:
    Edge: Spartan (44.19041.1266.0), Chromium (105.0.1343.27)
    Internet Explorer: 11.0.19041.1566
  npmPackages:
    vitepress: 1.0.0-alpha.13 => 1.0.0-alpha.13

Additional context

relative issue #324, but closed

Validations

  • Follow our Code of Conduct
  • Read the docs.
  • Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
@yeojongki yeojongki added the bug: pending triage Maybe a bug, waiting for confirmation label Sep 13, 2022
@brc-dd
Copy link
Member

brc-dd commented Sep 26, 2022

Same reason as #1399 (comment). Create an issue on their repo.

@brc-dd brc-dd closed this as not planned Won't fix, can't repro, duplicate, stale Sep 26, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug: pending triage Maybe a bug, waiting for confirmation
Projects
None yet
Development

No branches or pull requests

2 participants