Skip to content

[takeover] Change in one ts file does not reflect diagnostics in another file #3229

@rchl

Description

@rchl

I'm not sure if this affects only takeover mode (ts/js files) or also Vue files but I would suspect that it does affect all.

  1. Create files:

file1.ts

export const x = 1;

file2.ts

import { x } from './file1';

export const y = x + 2;
  1. change 1 in the first file to 'str'.
  2. Switch to file 2

Expected: file2 shows an error because number and string can't be added.
Actual: file2 does not show any error until something is changed in the file.

It doesn't seem like Volar listens to the tsserver events (syntaxDiag, semanticDiag) that update diagnostics.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions