这是indexloc提供的服务,不要输入任何密码
Skip to content

Files that are not matched by tsconfig should be ignored in headless #44

@camchenry

Description

@camchenry

When testing integration with oxlint, I noticed that the "file ... is not matched by tsconfig" was hit fairly often:

writeErrorMessage(fmt.Sprintf("file %v is not matched by tsconfig", fileConfig.FilePath))

I was attempting to lint the microsoft/vscode repository using the blanket tsconfig at src/tsconfig.json, in essence running:

oxlint vscode --tsconfig vscode/src/tsconfig.json

This lints all .js, .ts, .mjs, .jsx, .tsx, etc. files by default. However, it is likely that these files are not included in the tsconfig.json file, so it triggers this error message.

The question is: should we trigger an error by default here? I feel like it would be difficult in oxlint to filter every single file by whether it also matches the files in tsconfig.json. I think it would make sense to disable the typed lint rules (don't return any diagnostics) if it's not in the tsconfig.json.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions