I need a typescript compiler flag(option) recently introduced in typescript(1.8.0 nightly build) for my project, but grunt-typescript does not seem to be picking up the new version of typescript compiler from my typescript npm install, and also tried to manually copied over the new version of typescript bits under "node_modules\grunt-typescript\node_modules\typescript", still no luck.
By simply doing below, I confirmed that the typescript compiler version I applied can actually respect the new flag(forceConsistentCasingInFileNames) I want to apply, but I could not make it work for grunt-typescript.
node <project_path>\node_modules\grunt-typescript\node_modules\typescript\bin\tsc --forceConsistentCasingInFileNames hello.ts hello1.ts test.ts error TS1149: File name 'test.ts' differs from already included file name '../TeSt/test.ts' only in casing
For reference, here is my gruntfile, by using it to build same ts files, I don't get the compiler error, which is what I expect in this case by specifying the compile option(forceConsistentCasingInFileNames).
module.exports = function (grunt) {
grunt.initConfig({
typescript: {
base: {
src: ['*.ts'],
dest: '',
options: {
module: 'amd', //or commonjs
target: 'es5', //or es3
sourceMap: false,
declaration: false,
forceConsistentCasingInFileNames: true
}
}
}
});
grunt.loadNpmTasks('grunt-typescript');
grunt.registerTask('default', ['typescript:base']);
};
I need a typescript compiler flag(option) recently introduced in typescript(1.8.0 nightly build) for my project, but grunt-typescript does not seem to be picking up the new version of typescript compiler from my typescript npm install, and also tried to manually copied over the new version of typescript bits under "node_modules\grunt-typescript\node_modules\typescript", still no luck.
By simply doing below, I confirmed that the typescript compiler version I applied can actually respect the new flag(forceConsistentCasingInFileNames) I want to apply, but I could not make it work for grunt-typescript.
node <project_path>\node_modules\grunt-typescript\node_modules\typescript\bin\tsc --forceConsistentCasingInFileNames hello.ts hello1.ts test.ts error TS1149: File name 'test.ts' differs from already included file name '../TeSt/test.ts' only in casing
For reference, here is my gruntfile, by using it to build same ts files, I don't get the compiler error, which is what I expect in this case by specifying the compile option(forceConsistentCasingInFileNames). module.exports = function (grunt) { grunt.initConfig({ typescript: { base: { src: ['*.ts'], dest: '', options: { module: 'amd', //or commonjs target: 'es5', //or es3 sourceMap: false, declaration: false, forceConsistentCasingInFileNames: true } } } }); grunt.loadNpmTasks('grunt-typescript'); grunt.registerTask('default', ['typescript:base']); };
Any thoughts?