Skip to content

Commit

Permalink
fix(babelrc): Fix babel config syntax error
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongzhi107 committed May 3, 2017
1 parent bce361a commit c00e85a
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 5 deletions.
2 changes: 2 additions & 0 deletions generator-packing/generators/app/templates/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
1. 启动开发模式
```
npm run serve
# window系统使用下面的命令
# npm run serve:normal
```

2. 在浏览器中预览网站 `http://localhost:8081`
Expand Down
2 changes: 1 addition & 1 deletion generator-packing/generators/app/templates/_package.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
"react-transform-catch-errors": "^1.0.2",<% } if (props.redux) { %>
"react-redux": "^5.0.2",
"redux": "^3.6.0",<% } %>
"packing": "^2.0.1"
"packing": "^2.0.2"
},
"devDependencies": {
"express": "^4.14.1",
Expand Down
2 changes: 1 addition & 1 deletion generator-packing/generators/app/templates/babelrc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"presets": [<% if (props.react) { %>
"react", <% } %>
["es2015", {"module": false}]
["es2015", {"module": false}],
"stage-0"
],

Expand Down
4 changes: 3 additions & 1 deletion generator-packing/generators/app/templates/config/packing.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ export default (packing) => {
// 网站自定义配置
p.rewriteRules = {
// 网站URL与模版的对应路由关系
'^/$': '/index.<%= templateExtension%>'
'^/$': '/index.<%= templateExtension%>',
// API转发
'^/api/(.*)': 'require!/mock/api/$1.js'
};

return p;
Expand Down
2 changes: 1 addition & 1 deletion generator-packing/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "generator-packing",
"version": "2.7.3",
"version": "2.7.4",
"description": "",
"homepage": "",
"author": {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "packing",
"description": "Webpack based web front-end development environment",
"version": "2.0.1",
"version": "2.0.2",
"repository": "zhongzhi107/packing",
"files": [
".eslintrc",
Expand Down

0 comments on commit c00e85a

Please sign in to comment.