diff --git a/lint-configs/.eslintignore b/lint-configs/.eslintignore index b512c09d4..3c3629e64 100644 --- a/lint-configs/.eslintignore +++ b/lint-configs/.eslintignore @@ -1 +1 @@ -node_modules \ No newline at end of file +node_modules diff --git a/lint-configs/.eslintrc.js b/lint-configs/.eslintrc.js index a1ebd902c..ea7ac3ea4 100644 --- a/lint-configs/.eslintrc.js +++ b/lint-configs/.eslintrc.js @@ -204,6 +204,10 @@ module.exports = { format: ['camelCase'], leadingUnderscore: 'allow', }, + { + selector: 'import', + format: null, // do not force conventions on imports + }, { selector: 'variable', // PascalCase for variables is added to allow exporting a singleton, function library, or bare object as in @@ -246,8 +250,7 @@ module.exports = { allow: [ '**/middleware/*', // the src/middleware directory doesn't export a module, it's just a namespace. '**/receivers/*', // the src/receivers directory doesn't export a module, it's just a namespace. - '**/types/**/*', - '**/types/*', // type heirarchies should be used however one wants + '**/types/**/*', // type heirarchies should be used however one wants ], }], @@ -296,6 +299,19 @@ module.exports = { 'symbol-description': 'off', }, }, + { + files: ['test/types/**/*.test-d.ts'], + extends: ['plugin:@typescript-eslint/disable-type-checked'], + rules: { + 'import/no-internal-modules': ['error', { + // Use the following option to set a list of allowable globs in this project. + allow: [ + '**/src/**/*', // allow type tests to reach into src/ + '**/types/**/*', // type heirarchies should be used however one wants + ], + }], + } + }, ], }; diff --git a/packages/oauth/package.json b/packages/oauth/package.json index 8066c2513..4f3d59258 100644 --- a/packages/oauth/package.json +++ b/packages/oauth/package.json @@ -34,7 +34,6 @@ "lint": "eslint --fix --ext .ts src", "test": "npm run lint && npm run test:mocha", "test:mocha": "nyc mocha --config .mocharc.json src/*.spec.js src/**/*.spec.js src/*.spec.ts src/**/*.spec.ts", - "coverage": "codecov -F oauthhelper --root=$PWD", "ref-docs:model": "api-extractor run", "watch": "npx nodemon --watch 'src' --ext 'ts' --exec npm run build" }, @@ -47,29 +46,28 @@ "lodash.isstring": "^4.0.1" }, "devDependencies": { - "@microsoft/api-extractor": "^7.19.4", - "@types/chai": "^4.2.11", - "@types/mocha": "^9.1.0", - "@types/sinon": "^10.0.11", - "@typescript-eslint/eslint-plugin": "^4.4.1", - "@typescript-eslint/parser": "^4.4.0", - "chai": "^4.2.0", - "codecov": "^3.0.4", - "eslint": "^7.32.0", - "eslint-config-airbnb-base": "^14.2.1", - "eslint-config-airbnb-typescript": "^12.3.1", - "eslint-plugin-import": "^2.22.1", - "eslint-plugin-jsdoc": "^30.6.1", + "@microsoft/api-extractor": "^7.38.0", + "@types/chai": "^4.3.5", + "@types/mocha": "^10.0.1", + "@types/sinon": "^10.0.20", + "@typescript-eslint/eslint-plugin": "^6.4.1", + "@typescript-eslint/parser": "^6.4.0", + "chai": "^4.3.8", + "eslint": "^8.47.0", + "eslint-config-airbnb-base": "^15.0.0", + "eslint-config-airbnb-typescript": "^17.1.0", + "eslint-plugin-import": "^2.28.1", + "eslint-plugin-jsdoc": "^46.5.0", "eslint-plugin-node": "^11.1.0", - "mocha": "^9.2.1", + "mocha": "^10.2.0", "nop": "^1.0.0", "nyc": "^15.1.0", "rewiremock": "^3.13.9", "shx": "^0.3.2", - "sinon": "^9.0.2", - "source-map-support": "^0.5.12", + "sinon": "^15.2.0", + "source-map-support": "^0.5.21", "superagent": "^3.3.1", - "ts-node": "^8.2.0", + "ts-node": "^10.8.1", "typescript": "^4.1", "uncaughtException": "^1.0.0" } diff --git a/packages/oauth/src/callback-options.ts b/packages/oauth/src/callback-options.ts index a061edc9b..a37968bf0 100644 --- a/packages/oauth/src/callback-options.ts +++ b/packages/oauth/src/callback-options.ts @@ -118,6 +118,7 @@ export function defaultCallbackSuccess(
Redirecting to the Slack App... click here. If you use the browser version of Slack, click this link instead.