Skip to content

Commit

Permalink
fix: use consistent array type syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
haoqunjiang authored and sxzz committed Aug 28, 2023
1 parent 9fb7565 commit 25ce8a7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
1 change: 0 additions & 1 deletion .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ module.exports = defineConfig({
'node/no-unpublished-require': 'off',
'node/no-unsupported-features/es-syntax': 'off',

'@typescript-eslint/array-type': ['error', { default: 'array-simple' }],
'@typescript-eslint/ban-ts-comment': 'off', // TODO: we should turn this on in a new PR
'@typescript-eslint/ban-types': 'off', // TODO: we should turn this on in a new PR
'@typescript-eslint/explicit-module-boundary-types': [
Expand Down
2 changes: 1 addition & 1 deletion packages/plugin-vue/src/utils/descriptorCache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import type { ResolvedOptions, VueQuery } from '..'
// compiler-sfc should be exported so it can be re-used
export interface SFCParseResult {
descriptor: SFCDescriptor
errors: Array<CompilerError | SyntaxError>
errors: (CompilerError | SyntaxError)[]
}

export const cache = new Map<string, SFCDescriptor>()
Expand Down
8 changes: 4 additions & 4 deletions playground/test-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -193,18 +193,18 @@ type UntilBrowserLogAfterCallback = (logs: string[]) => PromiseLike<void> | void

export async function untilBrowserLogAfter(
operation: () => any,
target: string | RegExp | Array<string | RegExp>,
target: string | RegExp | (string | RegExp)[],
expectOrder?: boolean,
callback?: UntilBrowserLogAfterCallback,
): Promise<string[]>
export async function untilBrowserLogAfter(
operation: () => any,
target: string | RegExp | Array<string | RegExp>,
target: string | RegExp | (string | RegExp)[],
callback?: UntilBrowserLogAfterCallback,
): Promise<string[]>
export async function untilBrowserLogAfter(
operation: () => any,
target: string | RegExp | Array<string | RegExp>,
target: string | RegExp | (string | RegExp)[],
arg3?: boolean | UntilBrowserLogAfterCallback,
arg4?: UntilBrowserLogAfterCallback,
): Promise<string[]> {
Expand All @@ -221,7 +221,7 @@ export async function untilBrowserLogAfter(
}

async function untilBrowserLog(
target?: string | RegExp | Array<string | RegExp>,
target?: string | RegExp | (string | RegExp)[],
expectOrder = true,
): Promise<string[]> {
let resolve: () => void
Expand Down

0 comments on commit 25ce8a7

Please sign in to comment.