You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
when I use useAudioRecorder only, it shows failed to load ffmpeg core.
but when I use hook and UI Components, it shows ok. how to solve it?
My Project based on NextJS 14.
here is my stack:
yarn run v1.22.21
$ next dev
▲ Next.js 14.0.4
- Local: http://localhost:3000
✓ Ready in 3.5s
○ Compiling /chat/[type] ...
⨯ ./node_modules/@ffmpeg/ffmpeg/src/browser/defaultOptions.js:7:0
Module not found: Can't resolve '/node_modules/@ffmpeg/core/dist/ffmpeg-core.js'
https://nextjs.org/docs/messages/module-not-found
Import trace for requested module:
./node_modules/@ffmpeg/ffmpeg/src/browser/index.js
./node_modules/@ffmpeg/ffmpeg/src/index.js
./app/(page)/chat/hooks/useAudio.tsx
./app/(page)/chat/_component/audio-chat/audio-chat.tsx
⨯ ./node_modules/@ffmpeg/ffmpeg/src/browser/defaultOptions.js:7:0
Module not found: Can't resolve '/node_modules/@ffmpeg/core/dist/ffmpeg-core.js'
https://nextjs.org/docs/messages/module-not-found
Import trace for requested module:
./node_modules/@ffmpeg/ffmpeg/src/browser/index.js
./node_modules/@ffmpeg/ffmpeg/src/index.js
./app/(page)/chat/hooks/useAudio.tsx
./app/(page)/chat/_component/audio-chat/audio-chat.tsx
⨯ ./node_modules/@ffmpeg/ffmpeg/src/browser/defaultOptions.js:7:0
Module not found: Can't resolve '/node_modules/@ffmpeg/core/dist/ffmpeg-core.js'
https://nextjs.org/docs/messages/module-not-found
Import trace for requested module:
./node_modules/@ffmpeg/ffmpeg/src/browser/index.js
./node_modules/@ffmpeg/ffmpeg/src/index.js
./app/(page)/chat/hooks/useAudio.tsx
./app/(page)/chat/_component/audio-chat/audio-chat.tsx
⚠ Fast Refresh had to perform a full reload due to a runtime error.
✓ Compiled /favicon.ico in 161ms (485 modules)
To Reproduce
Steps to reproduce the behavior:
Expected behavior
run success.
Screenshots
Package info (please complete the following information):
Version [e.g. 22]
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
maybe the reason is that I use the hook in my hook. maybe my hook will compile in the server(because nextjs default render in server side). it cause the problem. but I dont know how to fix it. I explore all of the hook in my components.
@tsensei I just use the hooks in my client component directly, just use it in the use client tsx file. I think the client component not compile on the server side, so it will not show the problem.
Describe the bug
when I use
useAudioRecorder
only, it shows failed to load ffmpeg core.but when I use hook and UI Components, it shows ok. how to solve it?
My Project based on NextJS 14.
here is my stack:
To Reproduce
Steps to reproduce the behavior:
Expected behavior
run success.
Screenshots
![image](https://private-user-images.githubusercontent.com/12930558/291265906-59c8f51a-b4d6-4dbb-8d91-1de70977da02.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjUxMDg4NTAsIm5iZiI6MTcyNTEwODU1MCwicGF0aCI6Ii8xMjkzMDU1OC8yOTEyNjU5MDYtNTljOGY1MWEtYjRkNi00ZGJiLThkOTEtMWRlNzA5NzdkYTAyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MzElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODMxVDEyNDkxMFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWI0ZTQyNGI3ZTVkODgwMWIzYmI5YTYxMjUzOTRjZThhOWNjNDc0NzJkYWRjMmUyYTVkYjQ5MmI1ZDg0NzIzNGYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.eUUQKimwoJhIYx47VSXsK-dC6cRSt9EFkU45ESRj694)
Package info (please complete the following information):
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: