-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Closed
Labels
CanonicalThis issue contains a lengthy and complete description of a particular problem, solution, or designThis issue contains a lengthy and complete description of a particular problem, solution, or designWorking as IntendedThe behavior described is the intended behavior; this is not a bugThe behavior described is the intended behavior; this is not a bug
Description
TypeScript Version: nightly (2.1.0-dev.20160722)
Code
// src/views/foo.ts
import foo from 'view/bar';
console.log('Hi ', foo);// generated/templates/views/bar.ts
let foo = 'foo'
export default foo;// tsconfig.json
{
"compilerOptions": {
"baseUrl": ".",
"paths": {
"view/*": ["generated/templates/views/*"]
},
"outDir": "dist"
}
}Expected behavior:
the import foo from 'views/bar'; in src/views/foo.ts should generate 'var bar_1 = require('../../../view/bar');' because I've already define it with path mapping, It should relative path or not ?
Actual behavior:
the import foo from 'views/bar'; insrc/views/foo.tsgenerate 'var bar_1 = require('view/bar');
if you don't understand my english you should try by yourself ts-path-mapping
Sorry for my bad eng, Thank you :)
Metadata
Metadata
Assignees
Labels
CanonicalThis issue contains a lengthy and complete description of a particular problem, solution, or designThis issue contains a lengthy and complete description of a particular problem, solution, or designWorking as IntendedThe behavior described is the intended behavior; this is not a bugThe behavior described is the intended behavior; this is not a bug