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转换过滤bug|PC|athena1.4.3 #76

Open
Rococolate opened this issue Oct 13, 2017 · 0 comments
Open

babel转换过滤bug|PC|athena1.4.3 #76

Rococolate opened this issue Oct 13, 2017 · 0 comments

Comments

@Rococolate
Copy link

Rococolate commented Oct 13, 2017

我在写业务时会引入几个库如:

  <%= getJS('tweenjs-0.6.2.min.js') %>
  <%= getJS('preloadjs-0.6.2.min.js') %>
  <%= getJS('easeljs-0.8.2.min.js') %>
  <%= getJS('soundjs-0.6.2.min.js') %>
  <%= getJS('zepto.min.js') %>
  <%= getJS('zepto.animation.js') %>
  <%= getJS() %>

因为我不想库文件被转换了所以在配置时排除

useBabel: {
      enable: true,
      jsxPragma: 'Nerv.createElement', // jsx转换支持,默认为 React.createElement
      exclude: [ // 排除掉不需要转义的文件
        'static/js/easeljs-0.8.2.min.js',
        'static/js/preloadjs-0.6.2.min.js',
        'static/js/soundjs-0.6.2.min.js',
        'static/js/tweenjs-0.6.2.min.js',
        'static/js/zepto.animation.js',
        'static/js/zepto.min.js',
      ]
    },

然后用 ath s 启动服务,但当我修改业务代码,保存后发现以上库文件都会报错,
应该是被babel修改了。

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

1 participant