Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

wepy-cli 在根据组件内的 config 属性生成 .json 文件后,并没有运行 plugins 插件 #403

Closed
ystarlongzi opened this issue Sep 21, 2017 · 6 comments

Comments

@ystarlongzi
Copy link
Contributor

此问题源自于 #196,想根据在构建时的环境参数,动态修改 config 的部分属性值。

然后看了下和文件编译相关的代码,发现

都有执行 plugins 相关的代码,如下:

let plg = new loader.PluginHelper(config.plugins, {
  // ....
});

然后,发现在 compile-config.js 并没有执行 plugin 相关的代码,然后就导致了 #196 这个问题

@Gcaufy
Copy link
Collaborator

Gcaufy commented Sep 22, 2017

这个需要使用replace插件没有办法实现么?

@ystarlongzi
Copy link
Contributor Author

ystarlongzi commented Sep 22, 2017

@Gcaufy
没办法实现吧。我在这个issue 402#issuecomment-331332930 里解释我这个需求的原因

Gcaufy added a commit that referenced this issue Oct 10, 2017
@ystarlongzi
Copy link
Contributor Author

@Gcaufy wepy-cli 升级到 v1.5.9-2 后, /wepy-cli/lib/compile-config.js 还是旧的代码

@ystarlongzi
Copy link
Contributor Author

@Gcaufy 是这样的嘛?

@Gcaufy
Copy link
Collaborator

Gcaufy commented Oct 16, 2017

刚发了个1.5.9-3,你再试试

@ystarlongzi
Copy link
Contributor Author

@Gcaufy 可以啦,威武~~

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

No branches or pull requests

2 participants