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

When DocSidebar is swizzled, arrow.svg is missing #3830

Closed
mfaux opened this issue Nov 27, 2020 · 0 comments · Fixed by #3854
Closed

When DocSidebar is swizzled, arrow.svg is missing #3830

mfaux opened this issue Nov 27, 2020 · 0 comments · Fixed by #3854
Labels
bug An error in the Docusaurus core causing instability or issues with its execution

Comments

@mfaux
Copy link

mfaux commented Nov 27, 2020

🐛 Bug Report

When DocSidebar is swizzled, a ModuleNotFoundError occurs due to arrow.svg missing.

Have you read the Contributing Guidelines on issues

Yes.

To Reproduce

  1. Initialize a new project by running:

    npx @docusaurus/init@latest init my-website classic
    
  2. Swizzle the DocSidebar component:

    npm run swizzle @docusaurus/theme-classic DocSidebar
    
  3. Run docusaurus:

    npm start
    

Expected behavior

No errors should occur.

Actual Behavior

The following error appears in the terminal:

./src/theme/DocSidebar/styles.module.css
ModuleNotFoundError: Module not found: Error: Can't resolve '../icons/arrow.svg' in 'C:\temp\my-website\src\theme\DocSidebar'
 @ ./src/theme/DocSidebar/index.js 6:541-581 9:634-640 9:2413-2419 9:2430-2436 9:2478-2484 9:2587-2593 9:2706-2712 9:2755-2761 9:3172-3178 9:3195-3201 9:3303-3309 9:4133-4139
 @ ./node_modules/@docusaurus/theme-classic/lib/theme/DocPage/index.js
 @ ./.docusaurus/registry.js
 @ ./node_modules/@docusaurus/core/lib/client/exports/ComponentCreator.js
 @ ./.docusaurus/routes.js
 @ ./node_modules/@docusaurus/core/lib/client/clientEntry.js
 @ multi ./node_modules/react-dev-utils/webpackHotDevClient.js ./node_modules/@docusaurus/core/lib/client/clientEntry.js

Your Environment

  • Docusaurus version used: 2.0.0-alpha.69
@mfaux mfaux added bug An error in the Docusaurus core causing instability or issues with its execution status: needs triage This issue has not been triaged by maintainers labels Nov 27, 2020
@mfaux mfaux changed the title arrow.svg missing When DocSidebar is swizzled, arrow.svg is missing Nov 27, 2020
@Josh-Cena Josh-Cena removed the status: needs triage This issue has not been triaged by maintainers label Mar 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An error in the Docusaurus core causing instability or issues with its execution
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants