Skip to content

Commit

Permalink
Refactor to ECMA6 (babel) and JS class added
Browse files Browse the repository at this point in the history
  • Loading branch information
jbaylina committed Feb 10, 2017
1 parent 7cdae6b commit c86e6db
Show file tree
Hide file tree
Showing 15 changed files with 942 additions and 507 deletions.
7 changes: 7 additions & 0 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"presets": ["es2015", "stage-2"],
"plugins": [
"add-module-exports"
]
}

46 changes: 46 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
"env": {
"browser": true,
"es6": true,
"node": true,
"mocha": true
},
"extends": "airbnb",
"parser": "babel-eslint",
"rules": {
// indentation
"indent": [ 2, 4 ],

// spacing
"template-curly-spacing": [ 2, "always" ],
"array-bracket-spacing": [ 2, "always" ],
"object-curly-spacing": [ 2, "always" ],
"computed-property-spacing": [ 2, "always" ],
"no-multiple-empty-lines": [ 2, { "max": 1, "maxEOF": 0, "maxBOF": 0 } ],

// strings
"quotes": [ 2, "double", "avoid-escape" ],

// code arrangement matter
"no-use-before-define": [ 2, { "functions": false } ],

// make it meaningful
"prefer-const": 1,

// keep it simple
"complexity": [ 1, 5 ],

// Consisten return
"consistent-return": 0,

// Allow concatenations
"prefer-template": 0,

"import/no-extraneous-dependencies": ["error", {"devDependencies": ["**/*.test.js", "**/*.spec.js", "**/compile.js", "**/test/*.js"]}],

// react
"react/prefer-es6-class": 0,
"react/jsx-filename-extension": 0,
"react/jsx-indent": [ 2, 4 ]
}
}
1 change: 0 additions & 1 deletion Controlled.bin

This file was deleted.

1 change: 0 additions & 1 deletion MiniMeToken.bin

This file was deleted.

1 change: 0 additions & 1 deletion MiniMeTokenFactory.bin

This file was deleted.

Empty file removed TokenController.bin
Empty file.
2 changes: 0 additions & 2 deletions MiniMeToken.sol → contracts/MiniMeToken.sol
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,6 @@ contract MiniMeToken is Controlled {
decimals = _decimalUnits; // Set the decimals
symbol = _tokenSymbol; // Set the symbol
parentToken = MiniMeToken(_parentToken);
parentSnapShotBlock = _parentSnapShotBlock;
transfersEnabled = _transfersEnabled;
creationBlock = block.number;
}

Expand Down
Loading

0 comments on commit c86e6db

Please sign in to comment.