umijs / umi

A framework in react community ✨
https://umijs.org
MIT License
15.25k stars 2.65k forks source link

[Bug] mfsu breaks source map #7321

Closed cagen closed 2 years ago

cagen commented 2 years ago

What happens?

There are warning about source maps when turn on mfsu. And lots of node_modules packages cannot be mapped.

DevTools failed to load source map: Could not parse content for http://localhost:8000/react-router.js.map: Unexpected token < in JSON at position 0
DevTools failed to load source map: Could not parse content for http://localhost:8000/index.js.map: Unexpected token < in JSON at position 0
DevTools failed to load source map: Could not parse content for http://localhost:8000/react-router-config.js.map: Unexpected token < in JSON at position 0

image

Mini Showcase Repository(REQUIRED)

Please provide a repository using yarn create @umijs/umi-app then upload to your GitHub 请提供一个可复现的仓库,使用 yarn create @umijs/umi-app 创建,并上传到你的 GitHub 仓库

https://github.com/cagen/umi-test

How To Reproduce

Steps to reproduce the behavior:

  1. npx @umijs/create-umi-app
  2. add mfsu: {} in .umirc.ts
  3. npm start
  4. open chrome devtools to see the warnings

Expected behavior There should not be any source maps warnings, and node_modules packages can be mapped correctly.

Context

chenzio commented 2 years ago

Have the same problem

perny commented 2 years ago

同样的问题 按照AntdPro官网初始化的项目,结果出现了这个问题 1.npx create-umi xxx 2.? Select the boilerplate type (Use arrow keys) -> ant-design-pro 3.? 🤓 Which language do you want to use? (Use arrow keys) -> JavaScript

  1. ? 🚀 Do you need all the blocks or a simple scaffold? (Use arrow keys) -> simple
  2. cd xxx && npm install
  3. npm run start 环境 nodejs12 macOS WechatIMG4
flycj commented 2 years ago

同样的问题 按照AntdPro官网初始化的项目,结果出现了这个问题 1.npx create-umi xxx 2.? Select the boilerplate type (Use arrow keys) -> ant-design-pro 3.? 🤓 Which language do you want to use? (Use arrow keys) -> JavaScript 4. ? 🚀 Do you need all the blocks or a simple scaffold? (Use arrow keys) -> simple 5. cd xxx && npm install 6. npm run start 环境 nodejs12 macOS WechatIMG4

你好,你解决这个问题了吗?

xakxak007 commented 2 years ago

我也遇到了相同的问题

Alt-er commented 2 years ago

遇到同样的问题 请问解决了吗?

perny commented 2 years ago

同样的问题 按照AntdPro官网初始化的项目,结果出现了这个问题 1.npx create-umi xxx 2.? Select the boilerplate type (Use arrow keys) -> ant-design-pro 3.? 🤓 Which language do you want to use? (Use arrow keys) -> JavaScript 4. ? 🚀 Do you need all the blocks or a simple scaffold? (Use arrow keys) -> simple 5. cd xxx && npm install 6. npm run start 环境 nodejs12 macOS WechatIMG4

你好,你解决这个问题了吗?

并没有

hb1707 commented 2 years ago

Have the same problem

KrishnaPG commented 2 years ago

How to make the source-map files work? Getting the same error on Windows 10 with node.js v16.13.0 also.

umi: 3.5.20 umi-serve": ^1.9.10

codering commented 2 years ago

+1 !! @sorrycc so

licoded commented 2 years ago

+1 感觉使用ant-design-pro的人挺多,却没人给点帮助,比较失望

zhenghub commented 2 years ago

+1

hlskysong commented 2 years ago

umi: 3.5.0 Have the same problem

beatzcs commented 2 years ago

Have the same problem.

Mistrain-y-y commented 2 years ago

+1

Mistrain-y-y commented 2 years ago

+1

SmileKill commented 2 years ago

+1

Cyrusky commented 2 years ago

Why? Closed?

Cyrusky commented 2 years ago

@sorrycc , 为啥关了啊?

Cyrusky commented 2 years ago

Refer to: https://github.com/umijs/umi/issues/6996 a similar issue.

Known issue, so, just ignore it.