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

修正 babel 找不到 preset 的问题 #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

imyelo
Copy link

@imyelo imyelo commented Dec 21, 2018

fixes #2 .
不仅是 windows 下会存在问题,只要是以全局包的形式 (npm i -g wx-alipay) 使用 wxToalipay 都会使 babel 在 cwd 寻找 preset,导致出现 Couldn't find preset "es2015" relative to directory 的异常。

presets 中的字符串替换为 require.resolve(...) 的绝对路径结果可修正该问题。

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.

windows平台解决Couldn't find preset "es2015" relative to directory
1 participant