Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio Code: Cannot find name angular?

I have an Angular App and it works fine, but my debugger is showing me 'Cannot find name angular'.

 var table = angular.module('myTable', ['angularUtils.directives.dirPagination']); 

I included the link for angular in my html file:

<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>

I tried also including a link for bower_components also:

<script src="bower_components/angular/angular.min.js"></script>

There is a answer about this problem at Getting Error - Cannot find name 'angular' but I am not able to use it.

like image 292
John Onslaught Avatar asked Jul 05 '26 18:07

John Onslaught


1 Answers

Click on the lightbulb that will be next to 'angular' and then choose 'download typings'.

like image 185
user5890291 Avatar answered Jul 08 '26 09:07

user5890291



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!