我有问题,部署我的反应应用到Vercel。我认为由于Vercel无法解决'./index.css',所以它无法编译,不确定需要修改什么来解决这个问题。
以下是日志:
[12:22:08.385] Cloning completed: 1.218s
[12:22:08.459] Installing build runtime...
[12:22:10.412] Build runtime installed: 1.953s
[12:22:10.773] No Build Cache available
[12:22:10.926] Installing dependencies...
[12:22:20.413] npm WARN deprecated source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated
[12:22:20.902] npm WARN deprecated source-map-resolve@0.6.0: See https://github.com/lydell/source-map-resolve#deprecated
[12:22:24.009] npm WARN deprecated formidable@1.2.6: Please upgrade to latest, formidable@v2 or formidable@v3! Check these notes:
[12:22:26.196] npm WARN deprecated superagent@5.3.1: Please upgrade to v7.0.2+ of superagent. We have fixed numerous issues with streams, form-data, attach(), filesystem errors not bubbling up (ENOENT on attach()), and all tests are now passing. See the releases tab for more information at <https://github.com/visionmedia/superagent/releases>.
[12:22:26.972] npm WARN deprecated svgo@1.3.2: This SVGO version is no longer supported. Upgrade to v2.x.x.
[12:22:34.604]
[12:22:34.604] added 1420 packages in 23s
[12:22:34.605]
[12:22:34.605] 170 packages are looking for funding
[12:22:34.605] run `npm fund` for details
[12:22:34.830] Detected `package-lock.json` generated by npm 7...
[12:22:34.830] Running "npm run build"
[12:22:35.098]
[12:22:35.098] > collage@0.1.0 build
[12:22:35.099] > react-scripts build
[12:22:35.099]
[12:22:36.313] Creating an optimized production build...
[12:22:37.029] Failed to compile.
[12:22:37.030]
[12:22:37.030] Module not found: Error: Can't resolve './index.css' in '/vercel/path0/src'
[12:22:37.030]
[12:22:37.030]
[12:22:37.046] Error: Command "npm run build" exited with 1
发布于 2022-06-07 19:42:36
解决:大小写敏感问题。文件名从“Index.css”更新到“index.css”。
https://stackoverflow.com/questions/72536666
复制相似问题