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

Fix #43 #44

Merged
merged 2 commits into from
Jan 9, 2020
Merged

Fix #43 #44

merged 2 commits into from
Jan 9, 2020

Conversation

zcfan
Copy link
Contributor

@zcfan zcfan commented Jan 9, 2020

在处理顶层 path 时如果 path.stop() 会导致文件后面所有内容都不再处理。

require() 的语法必定处于一层 ExpressionStatement 下所以没有问题,node_modules 以外的 import 都会被转义为 require() 同样也没问题。

但 node_modules 文件夹下 babel 默认不处理,还保留着 import 语法,调用 stop 就导致跳过了整个 body 的处理。

image

@zcfan zcfan requested a review from Genuifx January 9, 2020 08:26
@codecov-io
Copy link

codecov-io commented Jan 9, 2020

Codecov Report

Merging #44 into dev will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff          @@
##             dev     #44   +/-   ##
=====================================
  Coverage   85.1%   85.1%           
=====================================
  Files         66      66           
  Lines       1202    1202           
  Branches     320     320           
=====================================
  Hits        1023    1023           
  Misses       136     136           
  Partials      43      43

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fbf5a72...5beb1d3. Read the comment docs.

@Genuifx Genuifx added the bug Something isn't working label Jan 9, 2020
@Genuifx Genuifx merged commit 1675fe6 into dev Jan 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants