From 68a7a1ccfb5f5c0558a555666cc6b20288c33788 Mon Sep 17 00:00:00 2001 From: Simon Warta Date: Wed, 1 Mar 2023 15:32:06 +0100 Subject: [PATCH] Adjust eslint config to make it work again --- .eslintrc.js | 10 +++++++++- packages/amino/.eslintrc.js | 14 ++++++++++++++ packages/cli/.eslintrc.js | 14 ++++++++++++++ packages/cosmwasm-stargate/.eslintrc.js | 14 ++++++++++++++ packages/crypto/.eslintrc.js | 14 ++++++++++++++ packages/encoding/.eslintrc.js | 14 ++++++++++++++ packages/faucet-client/.eslintrc.js | 14 ++++++++++++++ packages/faucet/.eslintrc.js | 14 ++++++++++++++ packages/json-rpc/.eslintrc.js | 14 ++++++++++++++ packages/ledger-amino/.eslintrc.js | 14 ++++++++++++++ packages/math/.eslintrc.js | 14 ++++++++++++++ packages/proto-signing/.eslintrc.js | 14 ++++++++++++++ packages/socket/.eslintrc.js | 14 ++++++++++++++ packages/stargate/.eslintrc.js | 14 ++++++++++++++ packages/stream/.eslintrc.js | 14 ++++++++++++++ packages/tendermint-rpc/.eslintrc.js | 14 ++++++++++++++ packages/utils/.eslintrc.js | 14 ++++++++++++++ 17 files changed, 233 insertions(+), 1 deletion(-) diff --git a/.eslintrc.js b/.eslintrc.js index 3749906c5c..74b1eaa582 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -65,7 +73,7 @@ module.exports = { // For object literal keys we want to allow things like numbers (e.g. 35), // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") selector: "objectLiteralProperty", - format: [null], + format: null, }, ], "@typescript-eslint/no-dynamic-delete": "warn", diff --git a/packages/amino/.eslintrc.js b/packages/amino/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/amino/.eslintrc.js +++ b/packages/amino/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/cli/.eslintrc.js b/packages/cli/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/cli/.eslintrc.js +++ b/packages/cli/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/cosmwasm-stargate/.eslintrc.js b/packages/cosmwasm-stargate/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/cosmwasm-stargate/.eslintrc.js +++ b/packages/cosmwasm-stargate/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/crypto/.eslintrc.js b/packages/crypto/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/crypto/.eslintrc.js +++ b/packages/crypto/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/encoding/.eslintrc.js b/packages/encoding/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/encoding/.eslintrc.js +++ b/packages/encoding/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/faucet-client/.eslintrc.js b/packages/faucet-client/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/faucet-client/.eslintrc.js +++ b/packages/faucet-client/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/faucet/.eslintrc.js b/packages/faucet/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/faucet/.eslintrc.js +++ b/packages/faucet/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/json-rpc/.eslintrc.js b/packages/json-rpc/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/json-rpc/.eslintrc.js +++ b/packages/json-rpc/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/ledger-amino/.eslintrc.js b/packages/ledger-amino/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/ledger-amino/.eslintrc.js +++ b/packages/ledger-amino/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/math/.eslintrc.js b/packages/math/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/math/.eslintrc.js +++ b/packages/math/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/proto-signing/.eslintrc.js b/packages/proto-signing/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/proto-signing/.eslintrc.js +++ b/packages/proto-signing/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/socket/.eslintrc.js b/packages/socket/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/socket/.eslintrc.js +++ b/packages/socket/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/stargate/.eslintrc.js b/packages/stargate/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/stargate/.eslintrc.js +++ b/packages/stargate/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/stream/.eslintrc.js b/packages/stream/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/stream/.eslintrc.js +++ b/packages/stream/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/tendermint-rpc/.eslintrc.js b/packages/tendermint-rpc/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/tendermint-rpc/.eslintrc.js +++ b/packages/tendermint-rpc/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off", diff --git a/packages/utils/.eslintrc.js b/packages/utils/.eslintrc.js index b76dd7be36..74b1eaa582 100644 --- a/packages/utils/.eslintrc.js +++ b/packages/utils/.eslintrc.js @@ -1,4 +1,12 @@ +// The master version of this file is in the repo root. Eslint seems to have +// problems using symbolic links for the config file, so we copy it to the packages. +// To update: +// 1. Go to the repo root +// 2. Make edits in .eslintrc.js +// 3. Run `find ./packages -name ".eslintrc.js" -exec cp .eslintrc.js {} \;` + module.exports = { + root: true, env: { es6: true, jasmine: true, @@ -61,6 +69,12 @@ module.exports = { format: ["strictCamelCase"], leadingUnderscore: "allow", }, + { + // For object literal keys we want to allow things like numbers (e.g. 35), + // type URLs (e.g. "/cosmos.feegrant.v1beta1.MsgGrantAllowance") or test data (e.g. "0.14ucoin2") + selector: "objectLiteralProperty", + format: null, + }, ], "@typescript-eslint/no-dynamic-delete": "warn", "@typescript-eslint/no-empty-function": "off",