Make Strict Mode Strict Again (#1938)
* fix: don't format "unorthodox" query input types
Also add support for tuples in `getSimilarTypes`
* fix: refactor type ignore logic into `formatType`
Had to use a regexp solution because types like `([AccountId | string | Uint8Array, Data | { none: any } | { raw: any } | { blakeTwo256: any } | { sha256: any } | { keccak256: any } | { shaThree256: any } | string | Uint8Array])[]` were not being ignored with the current logic, so they were passed to `getTypeDef` and causing delimiter errors.
* refactor: remove superfluous "FirstKeyType" param
* fix: ignore tuples with structs when formatting
* feat: eliminate all index signatures with --strict
* docs: fix doc generation
This commit is contained in:
@@ -10,9 +10,8 @@ export type AugmentedConst<T extends Codec> = T & ConstantCodec;
|
||||
|
||||
export type ModuleConstants = Record<string, Codec>;
|
||||
|
||||
export interface Constants {
|
||||
[index: string]: ModuleConstants;
|
||||
}
|
||||
// eslint-disable-next-line @typescript-eslint/no-empty-interface
|
||||
export interface Constants {}
|
||||
|
||||
export interface ConstantCodec extends Codec {
|
||||
meta: ModuleConstantMetadataLatest;
|
||||
|
||||
Reference in New Issue
Block a user