Skip to content

Commit

Permalink
Merge pull request #1929 from endojs/ta/optional-chaining
Browse files Browse the repository at this point in the history
leave no-optional-chaining out of exported 'recommended' lint config
  • Loading branch information
turadg authored Jan 8, 2024
2 parents e85d8a7 + 19dbdd8 commit f7fa702
Show file tree
Hide file tree
Showing 28 changed files with 52 additions and 52 deletions.
4 changes: 2 additions & 2 deletions packages/base64/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/check-bundle/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@
"build": "exit 0",
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava",
"test:c8": "c8 $C8_OPTIONS ava --config=ava-nesm.config.js"
Expand Down
4 changes: 2 additions & 2 deletions packages/cjs-module-analyzer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@
"build": "exit 0",
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "exit 0"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/compartment-mapper/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"prettier-fixtures": "prettier --write --with-node-modules './test/fixtures-*/**/*.*js'",
"test": "ava"
Expand Down
4 changes: 2 additions & 2 deletions packages/daemon/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/env-options/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
},
"scripts": {
"build": "exit 0",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
Expand Down
4 changes: 4 additions & 0 deletions packages/eslint-plugin/lib/configs/internal.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ module.exports = {
rules: {
// Work around https://github.com/import-js/eslint-plugin-import/issues/1810
'import/no-unresolved': ['error', { ignore: ['ava'] }],
// Agoric still uses Endo dependencies under an emulation of ESM we call RESM
// because it is invoked with `node -r esm`.
// RESM does not support ?? nor ?. operators, so we must avoid them expressly.
'@endo/no-optional-chaining': 'error',
},
overrides: [
{
Expand Down
4 changes: 0 additions & 4 deletions packages/eslint-plugin/lib/configs/recommended.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,6 @@ module.exports = {
rules: {
'@endo/assert-fail-as-throw': 'error',
'guard-for-in': 'error',
// Agoric still uses Endo dependencies under an emulation of ESM we call RESM
// because it is invoked with `node -r esm`.
// RESM does not support ?? nor ?. operators, so we must avoid them expressly.
'@endo/no-optional-chaining': 'warn',
'@endo/no-nullish-coalescing': 'warn',
},
};
4 changes: 2 additions & 2 deletions packages/exo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
"build": "exit 0",
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/lp32/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/marshal/test/test-marshal-capdata.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { makeMarshal } from '../src/marshal.js';

const { freeze, isFrozen, create, prototype: objectPrototype } = Object;

const harden = /** @type {import('ses').Harden & {isFake: boolean}} */ (
const harden = /** @type {import('ses').Harden & { isFake?: boolean }} */ (
// eslint-disable-next-line no-undef
global.harden
);
Expand Down
2 changes: 1 addition & 1 deletion packages/marshal/test/test-marshal-far-function.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { getInterfaceOf, passStyleOf, Far } from '@endo/pass-style';

const { freeze, setPrototypeOf } = Object;

const harden = /** @type {import('ses').Harden & {isFake: boolean}} */ (
const harden = /** @type {import('ses').Harden & { isFake?: boolean }} */ (
// eslint-disable-next-line no-undef
global.harden
);
Expand Down
2 changes: 1 addition & 1 deletion packages/marshal/test/test-marshal-smallcaps.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { roundTripPairs } from './test-marshal-capdata.js';

const { freeze, isFrozen, create, prototype: objectPrototype } = Object;

const harden = /** @type {import('ses').Harden & {isFake: boolean}} */ (
const harden = /** @type {import('ses').Harden & { isFake?: boolean }} */ (
// eslint-disable-next-line no-undef
global.harden
);
Expand Down
2 changes: 1 addition & 1 deletion packages/marshal/test/test-marshal-stringify.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { roundTripPairs } from './test-marshal-capdata.js';

const { isFrozen } = Object;

const harden = /** @type {import('ses').Harden & {isFake: boolean}} */ (
const harden = /** @type {import('ses').Harden & { isFake?: boolean }} */ (
// eslint-disable-next-line no-undef
global.harden
);
Expand Down
4 changes: 2 additions & 2 deletions packages/memoize/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
},
"scripts": {
"build": "exit 0",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
Expand Down
4 changes: 2 additions & 2 deletions packages/netstring/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/pass-style/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
"build": "exit 0",
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/patterns/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@
"build": "exit 0",
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/promise-kit/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-check": "yarn lint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava",
"test:xs": "exit 0"
Expand Down
4 changes: 2 additions & 2 deletions packages/ses-ava/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/ses/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@
"clean": "rm -rf dist",
"cover": "c8 ava",
"demo": "python3 -m http.server",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"prepare": "yarn run clean && yarn build",
"qt": "ava",
Expand Down
4 changes: 2 additions & 2 deletions packages/static-module-record/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint:types": "tsc",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint-fix": "eslint --fix .",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/stream-node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/stream/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/syrup/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/where/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/zip/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@
"build:types": "tsc --build tsconfig.build.json",
"clean:types": "git clean -f '*.d.ts*'",
"cover": "c8 ava",
"lint": "yarn lint:types && yarn lint:js",
"lint": "yarn lint:types && yarn lint:eslint",
"lint-fix": "eslint --fix .",
"lint:js": "eslint .",
"lint:eslint": "eslint .",
"lint:types": "tsc",
"test": "ava"
},
Expand Down

0 comments on commit f7fa702

Please sign in to comment.