错误提示:
info - Attempted to load @next/swc-linux-x64-gnu, but it was not installed
info - Attempted to load @next/swc-linux-x64-gnux32, but it was not installed
info - Attempted to load @next/swc-linux-x64-musl, but it was not installed
error - Failed to load SWC binary for linux/x64, see more info here: https://nextjs.org/docs/messages/failed-loading-swc
解决方法:
- 创建 .babelrc 文件
- 添加类容
{ "presets": ["next/babel"] }