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

fix: ssr require module failing with "Cannot find module './emojis'" #1784

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mhoffrog
Copy link

@mhoffrog mhoffrog commented Feb 10, 2025

πŸ”— Linked issue

#1783

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

This kind of issue was determined with Nuxt v3.15.3 only see nuxt-modules/MDC issue#318 for reference.

It has been fixed in Nuxt v3.15.4 by Nuxt PR fix(vite): restore externality for dev server externals #30802.

So this issue can be fixed by upgrading dependencies

  • update package.json:

    • dependencies:
      • nuxt ^3.15.3 -> ^3.15.4
      • @iconify-json/octicon ^1.2.2 -> ^1.2.4
      • @iconify-json/simple-icon ^1.2.22 -> ^1.2.24
    • devDependencies:
      • @nuxt/eslint ^1.0.0 -> ^1.0.1
      • eslint ^9.19.0 -> ^9.20.0
      • shiki ^2.1.0 -> ^2.3.2
      • vitest ^3.0.4 -> ^3.0.5
  • re-build pnpm-lock.yaml

Known Issue

Nuxt 3.15.4 is coming with a dependency update of @nuxt/cli to 3.21.1. This update fixes the typecheck command to let the node process end with an exit code <>0 if there are typecheck errors found. This is currently breaking this projects GitHub Action ci.xml. Fixing this projects typecheck violations should be subject of another PR.
See @nuxt/cli fix: throw when errors are #encountered

Test Results

image

No error is thrown anymore:
image

Page is rendering as expected:
image
image
image

- update package.json:
  - dependencies:
    - nuxt ^3.15.3 -> ^3.15.4
    - @iconify-json/octicon ^1.2.2 -> ^1.2.4
    - @iconify-json/simple-icon ^1.2.22 -> ^1.2.24
  - devDependencies:
    - @nuxt/eslint ^1.0.0 -> ^1.0.1
    - eslint ^9.19.0 -> ^9.20.0
    - shiki ^2.1.0 -> ^2.3.2
    - vitest ^3.0.4 -> ^3.0.5

- re-build pnpm-lock.yaml

closes nuxt#1783
@mhoffrog mhoffrog changed the title Update to fix ssr require module failing with "Cannot find module './emojis'" fix: ssr require module failing with "Cannot find module './emojis'" Feb 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant