-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9 from nanoporetech/improvement/code-refactor
Improvement/code refactor
- Loading branch information
Showing
15 changed files
with
2,824 additions
and
10,060 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,34 @@ | ||
module.exports = { | ||
parser: '@typescript-eslint/parser', // Specifies the ESLint parser | ||
// src has additional rules at src/.eslintrc.js | ||
module.exports = { | ||
root: true, | ||
parser: '@typescript-eslint/parser', | ||
parserOptions: { | ||
sourceType: 'module', | ||
ecmaVersion: 2020, | ||
}, | ||
plugins: ['@typescript-eslint', 'prettier'], | ||
extends: [ | ||
"plugin:@typescript-eslint/eslint-recommended", | ||
"plugin:@typescript-eslint/recommended", // Uses the recommended rules from the @typescript-eslint/eslint-plugin | ||
"plugin:@typescript-eslint/recommended-requiring-type-checking", | ||
'prettier/@typescript-eslint', // Uses eslint-config-prettier to disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier | ||
'plugin:prettier/recommended', // Enables eslint-plugin-prettier and displays prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array. | ||
'plugin:@typescript-eslint/recommended', | ||
'prettier/@typescript-eslint', // Uses eslint-config-prettier to disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier | ||
'plugin:prettier/recommended', // Enables eslint-plugin-prettier and eslint-config-prettier. This will display prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array. | ||
], | ||
parserOptions: { | ||
ecmaVersion: 2018, // Allows for the parsing of modern ECMAScript features | ||
sourceType: 'module', // Allows for the use of imports | ||
project: `./tsconfig.eslint.json` | ||
env: { | ||
browser: true, | ||
commonjs: true, | ||
node: true, | ||
mocha: true, | ||
es6: true, | ||
}, | ||
rules: { | ||
// Place to specify ESLint rules. Can be used to overwrite rules specified from the extended configs | ||
// e.g. "@typescript-eslint/explicit-function-return-type": "off", | ||
"@typescript-eslint/no-explicit-any": "off", | ||
"@typescript-eslint/explicit-module-boundary-types": "off", | ||
"@typescript-eslint/no-unsafe-member-access": "off", | ||
"@typescript-eslint/no-unsafe-assignment": "off", | ||
"@typescript-eslint/no-unsafe-return": "off", | ||
rules: { | ||
curly: 'error', | ||
'@typescript-eslint/camelcase': 'off', | ||
'@typescript-eslint/naming-convention': [ | ||
'error', | ||
{ selector: 'variable', format: ['camelCase', 'UPPER_CASE', 'PascalCase'] }, | ||
], | ||
'@typescript-eslint/ban-ts-comment': 'off', | ||
'@typescript-eslint/class-name-casing': 'off', | ||
'@typescript-eslint/no-empty-function': 'off', | ||
'prettier/prettier': 'error', | ||
}, | ||
}; |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{ | ||
"name": "@metrichor/jmespath", | ||
"description": "Typescript implementation of the JMESPath spec (100% compliant)", | ||
"version": "0.1.10", | ||
"version": "0.2.0", | ||
"author": { | ||
"name": "Oxford Nanopore Technologies", | ||
"email": "[email protected]", | ||
|
@@ -41,60 +41,44 @@ | |
"lint:fix": "npm run lint -- --fix", | ||
"prebuild": "rimraf dist", | ||
"perf": "node scripts/perf.js", | ||
"build": "tsc --outDir dist/lib -d --module commonjs --declarationDir dist/types && rollup -c rollup.config.ts", | ||
"build": "tsc --outDir dist/lib -d --module commonjs && rollup -c rollup.config.ts", | ||
"start": "rollup -c rollup.config.ts -w", | ||
"test": "jest --coverage", | ||
"test:watch": "jest --coverage --watch", | ||
"test:prod": "npm run lint && npm run test -- --no-cache", | ||
"deploy-docs": "ts-node scripts/gh-pages-publish", | ||
"report-coverage": "cat ./coverage/lcov.info | coveralls", | ||
"commit": "git-cz", | ||
"semantic-release": "semantic-release", | ||
"semantic-release-prepare": "ts-node scripts/semantic-release-prepare", | ||
"precommit": "lint-staged" | ||
}, | ||
"config": { | ||
"commitizen": { | ||
"path": "node_modules/cz-conventional-changelog" | ||
} | ||
}, | ||
"devDependencies": { | ||
"@commitlint/cli": "^11.0.0", | ||
"@commitlint/config-conventional": "^11.0.0", | ||
"@rollup/plugin-commonjs": "^15.1.0", | ||
"@rollup/plugin-commonjs": "^17.1.0", | ||
"@rollup/plugin-json": "^4.1.0", | ||
"@rollup/plugin-node-resolve": "^9.0.0", | ||
"@rollup/plugin-typescript": "^6.0.0", | ||
"@types/jest": "^26.0.14", | ||
"@types/node": "^14.11.8", | ||
"@typescript-eslint/eslint-plugin": "^4.4.0", | ||
"@typescript-eslint/parser": "^4.4.0", | ||
"@rollup/plugin-node-resolve": "^11.1.1", | ||
"@rollup/plugin-typescript": "^8.1.1", | ||
"@typescript-eslint/eslint-plugin": "^4.15.0", | ||
"@typescript-eslint/parser": "^4.15.0", | ||
"benchmark": "^2.1.4", | ||
"colors": "^1.4.0", | ||
"commitizen": "^4.2.1", | ||
"coveralls": "^3.1.0", | ||
"cz-conventional-changelog": "^3.3.0", | ||
"eslint": "^7.10.0", | ||
"eslint-config-prettier": "^6.12.0", | ||
"eslint-plugin-prettier": "^3.1.4", | ||
"husky": "^4.3.0", | ||
"jest": "^26.5.2", | ||
"jest-cli": "^26.5.2", | ||
"jest-config": "^26.5.2", | ||
"lint-staged": "^10.4.0", | ||
"prettier": "^2.1.2", | ||
"prettier-eslint": "^11.0.0", | ||
"prompt": "^1.0.0", | ||
"eslint": "^7.19.0", | ||
"eslint-config-prettier": "^7.2.0", | ||
"eslint-plugin-prettier": "^3.3.1", | ||
"husky": "^5.0.9", | ||
"jest": "^26.6.3", | ||
"jest-cli": "^26.6.3", | ||
"jest-config": "^26.6.3", | ||
"lint-staged": "^10.5.4", | ||
"prettier": "^2.2.1", | ||
"prettier-eslint": "^12.0.0", | ||
"prompt": "^1.1.0", | ||
"rimraf": "^3.0.2", | ||
"rollup": "^2.29.0", | ||
"rollup": "^2.38.5", | ||
"rollup-plugin-sourcemaps": "^0.6.3", | ||
"rollup-plugin-terser": "^7.0.2", | ||
"semantic-release": "^17.1.2", | ||
"shelljs": "^0.8.4", | ||
"ts-jest": "^26.4.1", | ||
"ts-node": "^9.0.0", | ||
"typedoc": "^0.19.2", | ||
"typescript": "^4.0.3" | ||
"ts-jest": "^26.5.1", | ||
"ts-node": "^9.1.1", | ||
"typedoc": "^0.20.23", | ||
"typescript": "^4.1.3" | ||
}, | ||
"dependencies": {} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.