Skip to content

Comments

增加parse参数,不改变postcss的ast结构#35

Open
wkstudy wants to merge 1 commit intosongsiqi:masterfrom
wkstudy:add-opts
Open

增加parse参数,不改变postcss的ast结构#35
wkstudy wants to merge 1 commit intosongsiqi:masterfrom
wkstudy:add-opts

Conversation

@wkstudy
Copy link

@wkstudy wkstudy commented May 14, 2022

详细起因经过点这里:vitejs/vite#7186
这里是简要描述:

  1. postcss的parse一般会接受参数opts,并且生成的ast的某些值依赖opts https://github.com/postcss/postcss/blob/24f2efc9a36d31c7a0cdf884804d3cfaea024be2/lib/parse.js#L7
  2. 我们这里没有传opts,导致ast少了属性input.file,而我在用的vite里的vite-url-plugin插件强依赖了这个属性导致最终打包出问题
  3. 我觉得ast还是不应该受到影响的,所以做了这个修改

感谢大佬

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

Successfully merging this pull request may close these issues.

1 participant