Skip to content

Commit

Permalink
Merge pull request electrode-io#1 from electrode-io/os
Browse files Browse the repository at this point in the history
os
  • Loading branch information
caoyangs authored Aug 19, 2016
2 parents 9d23d4c + 5db0059 commit 3e145c0
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 52 deletions.
3 changes: 0 additions & 3 deletions .builderrc

This file was deleted.

2 changes: 0 additions & 2 deletions .npmrc

This file was deleted.

2 changes: 1 addition & 1 deletion samples/electrode-demo-index/.babelrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"extends": "./node_modules/@walmart/electrode-archetype-react-component/config/babel/.babelrc"
"extends": "./node_modules/electrode-archetype-react-component/config/babel/.babelrc"
}
1 change: 1 addition & 0 deletions samples/electrode-demo-index/gulpfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
require("electrode-archetype-react-component")();
38 changes: 19 additions & 19 deletions samples/electrode-demo-index/package.json
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
{
"name": "@walmart/electrode-demo-index",
"version": "1.4.0",
"name": "electrode-demo-index",
"version": "1.0.0",
"description": "An extendable class for demos in Electrode components",
"main": "lib/index.js",
"repository": {
"type": "git",
"url": "git://gecgithub01.walmart.com/electrode/demo-index.git"
"url": "git://github.com/electrode-io/demo-index.git"
},
"scripts": {
"preversion": "builder run test",
"test:dev": "builder run test-frontend",
"test": "builder run check-cov && builder run cov-frontend",
"demo": "builder run server-dev",
"hot": "builder run server-hot",
"build": "npm run generate && builder run build-lib",
"preversion": "gulp test",
"test:dev": "gulp test-frontend",
"test": "gulp check-cov && gulp cov-frontend",
"demo": "gulp server-dev",
"hot": "gulp server-hot",
"build": "npm run generate && gulp build-lib",
"generate": "npm run generate-metadata && npm run generate-documentation",
"generate-metadata": "electrode-docgen --package ./package.json --src ./src --metadata components.json",
"generate-documentation": "electrode-docgen --package ./package.json --src ./src --markdown components.md",
"prepublish": "builder run build"
"prepublish": "gulp build"
},
"keywords": [],
"keywords": [
"electrode",
"demo"
],
"author": "Dave Stevens <[email protected]>",
"license": "UNLICENSED",
"license": "MIT",
"dependencies": {
"component-playground": "^1.3.0",
"warning": "^3.0.0"
"component-playground": "^1.3.1",
"object-assign": "^4.1.0"
},
"devDependencies": {
"@walmart/electrode-archetype-react-component": "^10.2.2",
"@walmart/electrode-archetype-react-component-dev": "^10.2.2",
"builder": "^2.10.1",
"react": "^0.14.8",
"react-dom": "^0.14.8"
"electrode-archetype-react-component": "^1.0.0",
"electrode-archetype-react-component-dev": "^1.0.0"
}
}
27 changes: 0 additions & 27 deletions samples/electrode-demo-index/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import React, { Component } from "react";
import ReactDOM from "react-dom";
import Playground from "component-playground";
import assign from "object-assign";
import warning from "warning";

const EMPTY_ARRAY = [];

Expand All @@ -29,32 +28,6 @@ export default class ElectrodeDemoIndex extends Component {
}
}

_setDemoContext(libraryScope, components) {
warning(
false,
"DEPRECATED! Extending ElectrodeDemoIndex has been deprecated and will be " +
"removed in the next major version. Please update the code: \n" +
"```\n" +
"export default class extends ElectrodeDemoIndex {\n" +
" componentDidMount () {\n" +
" this._setDemoContext(libraryScope, components);\n" +
" }\n" +
"}\n" +
"```\n" +
" to be:\n" +
"```\n" +
"export default () => (\n" +
" <ElectrodeDemoIndex libraryScope={libraryScope} components={components} />;\n" +
");\n" +
"```\n"
);

this.setState({
libraryScope,
components
});
}

render() {

const localScope = assign({ React, ReactDOM }, this.props.scope || {}, this.state.libraryScope);
Expand Down

0 comments on commit 3e145c0

Please sign in to comment.