Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[Bug] umijs3.5.41,通过chainWebpack设置devtool后,不生效 #12707

Open
gt-wangxueliang opened this issue Sep 19, 2024 · 5 comments
Open

Comments

@gt-wangxueliang
Copy link

What happens?

Mini Showcase Repository(REQUIRED)

Please provide a minimal reproduction then upload to your GitHub. 请提供 最小重现,并上传到你的 GitHub 仓库

How To Reproduce

Steps to reproduce the behavior: 1. 2.

Expected behavior 1. 2.

image
image
1、config.merge({
devtool: 'hidden-source-map',
});

2、config.devtool('hidden-source-map');
两种方式都尝试了,控制台打印也生效了,但是结果没有map文件

Context

  • Umi Version: 3.5.41
  • Node Version: 16.0.0
  • Platform: all
@xiaohuoni
Copy link
Member

有配置 devtool 可以设置

@gt-wangxueliang
Copy link
Author

嗯,是可以直接设置,也是生效的;
目前这个问题是不是新版本引入的,之前是生效的,最近发现这么使用,不会生成map

@xiaohuoni
Copy link
Member

嗯,是可以直接设置,也是生效的; 目前这个问题是不是新版本引入的,之前是生效的,最近发现这么使用,不会生成map

3.x 很久没更新了,你是在配置里面这么用,还是插件里面这么用?

@gt-wangxueliang
Copy link
Author

配置里用的。设置config的chainWebpack属性
image

@xiaohuoni
Copy link
Member

直接配置 devtool 吧,3.x 应该不会更新了

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@xiaohuoni @gt-wangxueliang and others