Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect reference path in generated definition file #50

Open
indapublic opened this issue Jul 6, 2015 · 0 comments
Open

Incorrect reference path in generated definition file #50

indapublic opened this issue Jul 6, 2015 · 0 comments

Comments

@indapublic
Copy link

Hello!

I successfully compiled my .ts script using command line:

tsc source/ts/docmaster/document/Explorer.class.ts --module commonjs --target ES5 --out source/ts/d.ts/docmaster/docmaster.js --declaration --noEmitOnError --removeComments

In compiled .d.ts file I see correctly used references.

/// <reference path="../DefinitelyTyped/jstorage/jstorage.d.ts" />
/// <reference path="../jquery/a2j.d.ts" />
/// <reference path="../DefinitelyTyped/q/Q.d.ts" />

I need to reproduce compiling in gulp script

gulp.task('test', function (callback) {
    gulp.src([
        'source/ts/docmaster/document/Explorer.class.ts'
    ])
        .pipe(tsc({
            module: 'commonjs',
            target: 'ES5',
            out: 'source/ts/d.ts/docmaster/docmaster.js',
            declaration: true,
            noEmitOnError: true,
            removeComments: true
        }))
        .pipe(gulp.dest(''))
        .pipe(notify('docmaster.js compiled'));
});

But in compiled d.ts my references are different:

/// <reference path="../../../../../source/ts/d.ts/DefinitelyTyped/jstorage/jstorage.d.ts" />
/// <reference path="../../../../../source/ts/d.ts/jquery/a2j.d.ts" />
/// <reference path="../../../../../source/ts/d.ts/DefinitelyTyped/q/Q.d.ts" />

Why?

@indapublic indapublic changed the title Cannot reproduce compilation behaviour in gulp-tsc Incorrect reference path in generated definition file Jul 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant