Skip to content

Commit ff69266

Browse files
committed
Merge pull request dozoisch#4 from dozoisch/update_builds_tools
Update builds tools & deps
2 parents 0fb9ea5 + 9059f9e commit ff69266

File tree

14 files changed

+52
-155
lines changed

14 files changed

+52
-155
lines changed

.babelrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@
33
"runtime",
44
"es7.objectRestSpread",
55
],
6+
"loose": "all",
67
}

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
lib/**

.travis.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,15 @@
11
sudo: false
22
language: node_js
33
node_js:
4-
- "iojs"
4+
- "4.0"
55
- "0.10"
66
- "0.12"
7+
8+
branches:
9+
only:
10+
- master
11+
12+
script:
13+
- npm run test
14+
- npm run lint
15+
- npm run build

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ With React 0.13, mixins are getting deprecated in favor of composition.
1313
After reading this article, [Mixins Are Dead. Long Live Composition][dan_abramov],
1414
I decided push react-script-loader a bit further and make a composition function that wraps component.
1515

16-
1716
## Usage
1817

1918
The api is very simple `makeAsyncScriptLoader(Component, scriptUrl, options)`. Where options can contain exposeFuncs, callbackName and globalName.
@@ -64,7 +63,7 @@ let reCAPTCHAprops = {
6463
};
6564

6665
React.render(
67-
<ReCAPTHAWrapper onLoad={onLoad} {...reCAPTCHAprops} />,
66+
<ReCAPTHAWrapper asyncScriptOnload={onLoad} {...reCAPTCHAprops} />,
6867
document.body
6968
);
7069
```

karma.conf.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"use strict";
33
require("babel/register");
44

5-
var webpackConfig = require("./webpack/test.config.js");
5+
var webpackConfig = require("./webpack.config.test.js");
66
var isCI = process.env.CONTINUOUS_INTEGRATION === "true";
77

88
module.exports = function (config) {

package.json

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,13 @@
44
"description": "A composition mixin for loading scripts asynchronously for React",
55
"main": "lib/async-script-loader.js",
66
"scripts": {
7-
"build": "node run-babel tools/build.js",
8-
"lint": "eslint src test tools webpack karma.conf.js",
9-
"test": "karma start --single-run && npm run build",
10-
"test-watch": "karma start"
7+
"build": "rm -rf lib && babel src --out-dir lib",
8+
"lint": "eslint ./",
9+
"test": "karma start --single-run",
10+
"test-watch": "karma start",
11+
"patch": "release patch --run",
12+
"minor": "release minor --run",
13+
"major": "release major --run"
1114
},
1215
"repository": {
1316
"type": "git",
@@ -27,30 +30,29 @@
2730
"devDependencies": {
2831
"babel": "~5.8.21",
2932
"babel-core": "~5.8.22",
30-
"babel-eslint": "~4.0.8",
33+
"babel-eslint": "~4.1.3",
3134
"babel-loader": "~5.3.2",
32-
"chai": "~3.2.0",
35+
"chai": "~3.3.0",
3336
"child-process-promise": "~1.1.0",
3437
"colors": "~1.1.0",
3538
"es5-shim": "~4.1.3",
36-
"eslint": "~1.1.0",
37-
"eslint-config-defaults": "~4.0.1",
38-
"eslint-plugin-react": "~3.2.3",
39-
"fs-promise": "~0.3.1",
39+
"eslint": "~1.6.0",
40+
"eslint-config-defaults": "~7.0.1",
41+
"eslint-plugin-react": "~3.5.1",
4042
"karma": "~0.13.9",
4143
"karma-chai": "~0.1.0",
4244
"karma-chrome-launcher": "~0.2.0",
4345
"karma-cli": "~0.1.0",
4446
"karma-mocha": "~0.2.0",
4547
"karma-mocha-reporter": "~1.1.1",
46-
"karma-phantomjs-launcher": "~0.2.1",
48+
"karma-phantomjs-launcher": "^0.2.1",
4749
"karma-sourcemap-loader": "~0.3.5",
4850
"karma-webpack": "~1.7.0",
49-
"lodash": "~3.10.1",
50-
"mocha": "~2.2.5",
51-
"react": "~0.13.3",
52-
"webpack": "~1.11.0",
53-
"yargs": "~3.19.0"
51+
"mocha": "~2.3.3",
52+
"mt-changelog": "^0.6.2",
53+
"react": "~0.14.0",
54+
"release-script": "^0.5.3",
55+
"webpack": "~1.12.2"
5456
},
5557
"dependencies": {
5658
"babel-runtime": "^5.8.0"

run-babel

Lines changed: 0 additions & 9 deletions
This file was deleted.

tools/build.js

Lines changed: 0 additions & 22 deletions
This file was deleted.

tools/lib/build.js

Lines changed: 0 additions & 16 deletions
This file was deleted.

webpack.config.test.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
import { DefinePlugin } from "webpack";
2+
export default {
3+
output: {
4+
pathinfo: true,
5+
},
6+
devtool: "inline-source-map",
7+
8+
module: {
9+
loaders: [
10+
{ test: /\.js/, loader: "babel", exclude: /node_modules/ },
11+
],
12+
},
13+
plugins: [
14+
new DefinePlugin({
15+
"process.env": {
16+
NODE_ENV: JSON.stringify("production"),
17+
},
18+
}),
19+
],
20+
};

webpack/strategies/index.js

Lines changed: 0 additions & 5 deletions
This file was deleted.

webpack/strategies/test.js

Lines changed: 0 additions & 17 deletions
This file was deleted.

webpack/test.config.js

Lines changed: 0 additions & 3 deletions
This file was deleted.

webpack/webpack.config.js

Lines changed: 0 additions & 63 deletions
This file was deleted.

0 commit comments

Comments
 (0)