TypeScript Error: Cannot find namespace 'google'

后端 未结 7 630
青春惊慌失措
青春惊慌失措 2021-01-12 06:33

I have project angular-cli

~root~/src/typings.json

{
  \"globalDevDependencies\": {
    \"angular-protractor\": \"registry:dt/angula         


        
7条回答
  •  执笔经年
    2021-01-12 07:33

    A bit of a late response but I had a similar issue using Angular CLI RC.0.

    It turned out that I hadn't install and imported the typings, which can be done as follows:

    npm install --save-dev @types/googlemaps
    
    import {} from '@types/googlemaps';
    

提交回复
热议问题