admin管理员组

文章数量:1323730

I have the Angular Language Service plugin installed in VSCode and it works fine for most of the angular code autocompletion. However, some of the autocomplete does not work, such as for Pipes and FormsModule. In WebStorm, it works fine.

VSCode

WebStorm

I have the Angular Language Service plugin installed in VSCode and it works fine for most of the angular code autocompletion. However, some of the autocomplete does not work, such as for Pipes and FormsModule. In WebStorm, it works fine.

VSCode

WebStorm

Share Improve this question edited Jan 12 at 8:09 ProgrammingLlama 38.9k7 gold badges77 silver badges102 bronze badges asked Jan 12 at 6:49 sm-sayedism-sayedi 95513 silver badges34 bronze badges
Add a comment  | 

2 Answers 2

Reset to default 0

I've searched for this issue and I found these three useful GitHub links that can help you:

  • Bug in VSCode Angular Language Service with autocomplete (solution included) : in here the asker founded that everything works correctly if strict typing is disabled within the plugin.
  • @angular/language-service slows down VSCode autocomplete on every keystroke : in order to find out why is this issue appearing, you can open the Output tab in VSCode, and check any warning or errors that can give you a clue of what is going on (discussed also in the 3rd link).
  • autocomplete not working on windows : In this link it's recommended that your project's tsconfig.json is correctly set up and that the Angular Language Service can find all necessary files (discussed also in the 2nd link).

Note that there are also many other related links for your problem (especially in the 2nd link).

I hope it helps you!

import { CommonModule } from '@angular/common';
    
@Component({
  selector: '*',
  imports: [CommonModule], // fix
  templateUrl: './*ponent.html',
  styleUrl: './*ponent.scss'
})

I solved this issue by importing CommonModule in each module in VSCode.

本文标签: visual studio codeAngular Pipes autocomplete doesn39t work in vscodeStack Overflow