Skip to content

typescript/no-use-before-define flags errors even when disabled #19437

@porada

Description

@porada

Please see oxlint.config.ts in the test repository.

~/P/oxlint-no-use-before-define 
$ pnpm oxlint --version
Version: 1.48.0


~/P/oxlint-no-use-before-define main
$ pnpm oxlint

  × typescript-eslint(no-use-before-define): 'defineConfig' was used before it was defined.
   ╭─[oxlint.config.ts:4:16]
 3 │ 
 4 │ export default defineConfig({
   ·                ──────┬─────
   ·                      ╰── used here
 5 │   categories: {
   ╰────
    ╭─[oxlint.config.ts:13:10]
 12 │ 
 13 │ function defineConfig<T extends OxlintConfig>(config: T): T {
    ·          ──────┬─────
    ·                ╰── defined here
 14 │   return oxlintDefineConfig(config);
    ╰────
  help: Move the declaration before any references to it, or remove the reference if it is not needed.

Found 0 warnings and 1 error.
Finished in 49ms on 1 file with 147 rules using 16 threads.

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions