-
-
Notifications
You must be signed in to change notification settings - Fork 726
Closed as not planned
Labels
Description
Environment
- Operating System:
Windows_NT - Node Version:
v16.13.1 - Nuxt Version:
3.0.0-rc.6 - Package Manager:
[email protected] - Builder:
vite - User Config:
app,typescript,modules,colorMode,content - Runtime Modules:
@nuxt/[email protected],@nuxtjs/[email protected],@nuxtjs/[email protected] - Build Modules:
-
Reproduction
https://github.com/Benbinbin/nuxt-content-local-remark-plugin
Describe the bug
The former documentation show how to use the local remark plugin, like ~/markdownPlugins/remark-plugin.js
but the new documentation delete this part
when I use the same syntax which is mentioned at the old documentation
export default defineNuxtConfig({
// ...
content: {
// ...
markdown: {
remarkPlugins: ['~/markdownPlugins/remarkPlugin.js']
}
}
})but then I get an error (see th Logs part 👇 ) it recognizes the local remark plugin file as a package?
maybe the old documentation just suitable for content v1, any new way to add local remark plugin for content v2?
Additional context
some relative issues about plugin:
Logs
[nuxt] [request error] Cannot find package '~' imported from D:\Work\Code\Web\Frontend\Nuxt\nuxt-content-local-remark-plugin\.nuxt\dev\index.mjs
at new NodeError (node:internal/errors:371:5)
at packageResolve (node:internal/modules/esm/resolve:884:9)
at moduleResolve (node:internal/modules/esm/resolve:929:18)
at defaultResolve (node:internal/modules/esm/resolve:1044:11)
at ESMLoader.resolve (node:internal/modules/esm/loader:422:30)
at ESMLoader.getModuleJob (node:internal/modules/esm/loader:222:40)
at ESMLoader.import (node:internal/modules/esm/loader:276:22)
at importModuleDynamically (node:internal/modules/esm/translators:111:35)
at importModuleDynamicallyCallback (node:internal/process/esm_loader:35:14)
at importPlugins (/D:/Work/Code/Web/Frontend/Nuxt/nuxt-content-local-remark-plugin/.nuxt/dev/index.mjs:1096:32)ManasMadrecha, innocenzi, pv-g and nwittwer