Skip to content

Commit

Permalink
Merge pull request #27 from gilbarbara/master
Browse files Browse the repository at this point in the history
rewrite src code in ES2015 and add `shouldComponentUpdate`
  • Loading branch information
gilbarbara committed Apr 19, 2016
2 parents a03afb0 + 21d51e5 commit 4763d2b
Show file tree
Hide file tree
Showing 24 changed files with 5,364 additions and 30,447 deletions.
184 changes: 184 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,184 @@
{
"extends": "airbnb",
"parser": "babel-eslint",
"env": {
"mocha": true
},
"globals": {
"$": true
},
"plugins": [
"jsdoc"
],
"rules": {
"arrow-body-style": [
1,
"as-needed"
],
"brace-style": [
1,
"stroustrup",
{
"allowSingleLine": true
}
],
"camelcase": 0,
"comma-dangle": 0,
"dot-notation": 1,
"indent": [
1,
2,
{
"SwitchCase": 1
}
],
"max-len": 0,
"newline-per-chained-call": [
1,
{
"ignoreChainWithDepth": 5
}
],
"no-case-declarations": 1,
"no-confusing-arrow": [
1,
{
"allowParens": true
}
],
"no-mixed-spaces-and-tabs": [
1,
"smart-tabs"
],
"no-multi-spaces": [
1,
{
"exceptions": {
"VariableDeclarator": true,
"Property": false
}
}
],
"no-nested-ternary": 1,
"no-param-reassign": [
1,
{
"props": false
}
],
"no-trailing-spaces": 1,
"no-unused-vars": 1,
"object-shorthand": [
1,
"always"
],
"one-var": 1,
"padded-blocks": 1,
"prefer-const": 1,
"prefer-template": 1,
"quotes": [
1,
"single",
"avoid-escape"
],
"require-jsdoc": [
0,
{
"require": {
"FunctionDeclaration": true,
"MethodDefinition": false,
"ClassDeclaration": false
}
}
],
"space-before-function-paren": [
1,
"never"
],
"space-in-parens": 1,
"spaced-comment": [
1,
"always",
{
"exceptions": [
"-+"
],
"markers": [
"eslint-disable",
"eslint-disable-line"
]
}
],
"valid-jsdoc": [
1,
{
"prefer": {
"return": "returns"
},
"requireReturn": false,
"requireParamDescription": false,
"requireReturnDescription": false
}
],
// JSDoc
"jsdoc/check-tag-names": 1,
"jsdoc/check-types": 1,
"jsdoc/newline-after-description": 1,
"jsdoc/require-description-complete-sentence": 0,
"jsdoc/require-hyphen-before-param-description": 1,
// React
"jsx-quotes": 1,
"react/jsx-closing-bracket-location": [
1,
"after-props"
],
"react/jsx-indent-props": [
1,
2
],
"react/jsx-key": 1,
"react/jsx-max-props-per-line": [
1,
{
"maximum": 4
}
],
"react/no-did-mount-set-state": 1,
"react/no-did-update-set-state": 1,
"react/jsx-boolean-value": 0,
"react/jsx-no-duplicate-props": 1,
"react/jsx-pascal-case": 1,
"react/no-direct-mutation-state": 1,
"react/prefer-stateless-function": 0,
"react/prop-types": 2,
"react/sort-prop-types": 1,
"react/sort-comp": [
1,
{
"order": [
"constructor",
"lifecycle",
"everything-else",
"render"
],
"groups": {
"lifecycle": [
"statics",
"contextTypes",
"childContextTypes",
"getChildContext",
"propTypes",
"defaultProps",
"shouldComponentUpdate",
"componentWillMount",
"componentDidMount",
"componentWillReceiveProps",
"componentWillUpdate",
"componentDidUpdate",
"componentWillUnmount"
]
}
}
]
}
}
5 changes: 1 addition & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
/node_modules/
/Gruntfile.js
/test/tests.js
/lib/
node_modules
14 changes: 6 additions & 8 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
/node_modules/
/Gruntfile.coffee
/test/
/vendor/
/bower.json
/coffeelint.json
/src/
/standalone/
bower.json
gulpfile.js
node_modules
src
standalone
test
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-inlinesvg",
"version": "0.4.2",
"version": "0.5.0",
"authors": [
"Matthew Dapena-Tretter <[email protected]>"
],
Expand Down
114 changes: 0 additions & 114 deletions coffeelint.json

This file was deleted.

62 changes: 0 additions & 62 deletions gulpfile.coffee

This file was deleted.

Loading

0 comments on commit 4763d2b

Please sign in to comment.