Skip to content

Commit c759704

Browse files
committed
chore: apply babel on publish
1 parent eaf949c commit c759704

File tree

2 files changed

+17
-13
lines changed

2 files changed

+17
-13
lines changed

.babelrc

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,17 @@
11
{
2-
"presets": [
3-
[
4-
"env",
5-
{
6-
"targets": {
7-
"node": "0.12"
8-
}
9-
}
10-
],
11-
"flow"
12-
]
13-
}
2+
"env": {
3+
"production": {
4+
"presets": [
5+
[
6+
"env",
7+
{
8+
"targets": {
9+
"node": "0.12"
10+
}
11+
}
12+
],
13+
"flow"
14+
]
15+
}
16+
}
17+
}

scripts/build.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ shell.ln('-s', '../../scripts/git-pre-push', '.git/hooks/pre-push');
4848
console.info(colors.bold('[3/3] Transpiling JS code...\n'));
4949

5050
shell.exec(
51-
`"node_modules/.bin/babel" ${process.argv[2] ||
51+
`NODE_ENV=production "node_modules/.bin/babel" ${process.argv[2] ||
5252
''} src/ --out-dir dist/ --ignore __tests__`
5353
);
5454

0 commit comments

Comments
 (0)