Comments (2)
`
successCallback /Users/Osx/github/.contentlayer
Local search index generated...
Generated 4 documents in .contentlayer
File updated: blog/test.mdx
✘ [ERROR] Could not resolve "path"
node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/next/dist/compiled/micromatch/index.js:22:3444:
22 │ ...=toRegexRange},17:e=>{e.exports=require("path")},837:e=>{e.exports=require("util")}};...
╵ ~~~~~~
The package "path" wasn't found on the file system but is built into node. Are you trying to
bundle for node? You can use "platform: 'node'" to do that, which will remove this error.
✘ [ERROR] Could not resolve "util"
node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/next/dist/compiled/micromatch/index.js:22:3479:
22 │ ...uire("path")},837:e=>{e.exports=require("util")}};var t={};function __nccwpck_require...
╵ ~~~~~~
The package "util" wasn't found on the file system but is built into node. Are you trying to
bundle for node? You can use "platform: 'node'" to do that, which will remove this error.
✘ [ERROR] Cannot import "node_modules/.pnpm/[email protected]/node_modules/swiper/swiper.css" into a JavaScript file without an output path configured
components/Slideshow/SlideShow.tsx:3:7:
3 │ import 'swiper/css'
╵ ~~~~~~~~~~~~
✘ [ERROR] Cannot import "node_modules/.pnpm/[email protected]/node_modules/swiper/modules/navigation.css" into a JavaScript file without an output path configured
components/Slideshow/SlideShow.tsx:4:7:
4 │ import 'swiper/css/navigation'
╵ ~~~~~~~~~~~~~~~~~~~~~~~
Error: Found 1 problems in 1 documents.
└── Encountered unexpected errors while processing of 1 documents. This is possibly a bug in Contentlayer. Please open an issue.
• "blog/test.mdx": UnexpectedMDXError: Error: Build failed with 4 errors:
components/Slideshow/SlideShow.tsx:3:7: ERROR: Cannot import "node_modules/.pnpm/[email protected]/node_modules/swiper/swiper.css" into a JavaScript file without an output path configured
components/Slideshow/SlideShow.tsx:4:7: ERROR: Cannot import "node_modules/.pnpm/[email protected]/node_modules/swiper/modules/navigation.css" into a JavaScript file without an output path configured
node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/next/dist/compiled/micromatch/index.js:22:3444: ERROR: Could not resolve "path"
node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected]/node_modules/next/dist/compiled/micromatch/index.js:22:3479: ERROR: Could not resolve "util"
successCallback /Users/Osx/github/.contentlayer
Local search index generated...
SourceFetchDataError: {
"_tag": "HandledFetchDataError"`
from tailwind-nextjs-starter-blog.
Try using this approach instead: https://github.com/timlrx/tailwind-nextjs-starter-blog/blob/main/faq/custom-mdx-component.md
Because of the two different build steps between contentlayer / markdown and the final website, only simple react component work if you are trying to import it directly.
from tailwind-nextjs-starter-blog.
Related Issues (20)
- Image syntax for videos do not work e.g. ![](/static/demo.mp4) HOT 2
- Help !! Navigation tabs not visible in Brave browser. HOT 8
- The list style is wrong HOT 3
- Gisus comment is not working HOT 5
- Contentlayer is no longer maintained and causing multiple build errors on first try HOT 10
- How to apply Incremental Static Regeneration? HOT 2
- Newsletter Color Scheme Change for Light and Dark mode. [Accessibility] HOT 3
- I cannot run ``yarn run dev`` on Windows 10 HOT 1
- CVE-2023-42282: NPM IP package vulnerable to Server-Side Request Forgery (SSRF) attacks HOT 1
- Integrating YT video canvases in MD HOT 4
- Date Mismatch from Tags Pages to Article itself and Main Page HOT 3
- adding Authjs HOT 1
- [Feature request] navbar dropdown HOT 4
- Font is showing in production but not in local HOT 1
- Add pagination to the tags page HOT 3
- Fails to deploy to Github Pages HOT 4
- Unable to install HOT 3
- Where should I put this script? HOT 1
- Blog Posts with 'draft' Status Incorrectly Displayed HOT 2
- deploy vercel go wrong HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tailwind-nextjs-starter-blog.