Skip to content

TypeScript Definition File References #87

@bmingles

Description

@bmingles

Are ///<reference/> tags pointing to definition files supported in T3S?

Here's my project structure:

projectdir/
|  typings/
|  |  angularjs/
|  |  |  angular.d.ts  
|  project.sublime-project
|  my-root.ts

I currently have a single root file (my-root.ts) configured in my project:

{
    "settings":
    {
        "typescript":
        {
            "roots":
            [
                "projectdir/my-root.ts"
            ]
        }       
    }
}

my-root.ts then has a reference to angular.d.ts followed by usage of angular which is declared in the .d.ts file:

/// <reference path="typings/angularjs/angular.d.ts"/>
var AppModule = angular.module('AppModule', []);

Unfortunately, I get the error:

error TS2095: Could not find symbol 'angular'

It appears that the intellisense is unaware of files brought in via tags. Is this expected?


Also, not sure if it is related, but I also see the following error show up in the console during initialization:

TSS command processing error: TypeError: Cannot read property 'lineMap' of null

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions