Skip to content

Commit

Permalink
Merge pull request #5 from ololabs/update-tslint
Browse files Browse the repository at this point in the history
Update TSLint configs for TSLint 5.x.
  • Loading branch information
gshackles authored Oct 24, 2017
2 parents 8da690d + 8a007a9 commit f050b4f
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
language: node_js
node_js:
- "5"
- "6"
env:
- PACKAGE_DIR=packages/eslint-config-olo
- PACKAGE_DIR=packages/tslint-config-olo
- PACKAGE_DIR=packages/olo-gulp-helpers
script: cd $PACKAGE_DIR && npm install && npm run lint
script: cd $PACKAGE_DIR && yarn && yarn run lint
4 changes: 4 additions & 0 deletions packages/tslint-config-olo/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

This package provides Olo's shared TSLint configuration, to be used in all TypeScript applications.

**Note:** the rules are defined in `rules` and exported via `index.js`. The `.eslintrc` is present so we can lint the rules files with our standard rules.

The v0.2.0 rule set assumes TypeScript 2.x.

## Usage

Specify the following in your `tslint.json` file:
Expand Down
5 changes: 4 additions & 1 deletion packages/tslint-config-olo/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "tslint-config-olo",
"version": "0.1.0",
"version": "0.2.0",
"description": "Olo's TSLint configs",
"main": "index.js",
"scripts": {
Expand All @@ -27,5 +27,8 @@
"devDependencies": {
"eslint": "^2.5.1",
"eslint-config-olo": "^0.1.1"
},
"peerDependencies": {
"typescript": "2"
}
}
6 changes: 1 addition & 5 deletions packages/tslint-config-olo/rules/functionality.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,20 @@ module.exports = {
'curly': true,
'forin': true,
'label-position': true,
'label-undefined': true,
'no-arg': true,
'no-bitwise': true,
'no-conditional-assignment': true,
'no-console': true,
'no-construct': true,
'no-debugger': true,
'no-duplicate-key': true,
'no-duplicate-variable': true,
'no-eval': true,
'no-invalid-this': true,
'no-null-keyword': true,
'no-shadowed-variable': true,
'no-string-literal': false,
'no-switch-case-fall-through': true,
'no-unreachable': true,
'no-unused-expression': true,
'no-unused-variable': [true, 'react', { 'ignore-pattern': 'React' }],
'no-use-before-declare': true,
'no-var-keyword': true,
'radix': true,
Expand All @@ -30,4 +26,4 @@ module.exports = {
'use-isnan': true,
'use-strict': true
}
};
};

0 comments on commit f050b4f

Please sign in to comment.