正则表达式 – 为什么VS代码中的问题匹配器不起作用?
发布时间:2020-12-14 02:29:33 所属栏目:百科 来源:网络整理
导读:为什么我的problemMatcher不起作用?我非常肯定正则表达式,但它没有报告任何问题,即使有一些关于stdout …… // the matcher"problemMatcher": { "owner": "typescript","fileLocation": ["relative","${workspaceRoot}"],"pattern": { "regexp": "^TypeScri
为什么我的problemMatcher不起作用?我非常肯定正则表达式,但它没有报告任何问题,即使有一些关于stdout ……
// the matcher "problemMatcher": { "owner": "typescript","fileLocation": ["relative","${workspaceRoot}"],"pattern": { "regexp": "^TypeScript (warning|error): (.*)((d+),(d+)): (.*)$","severity": 1,"file": 2,"line": 3,"column": 4,"message": 5 } } //the browserify/tsify pipeline browserify().add('main.ts') .plugin(tsify,{ noImplicitAny: false,removeComments:true }) .transform("babelify",{ extensions: ['.ts'],presets: ["es2015"]}) .bundle() .on('error',function (error) { console.log(error.toString()); }) .pipe(source('bundle.js')) .pipe(gulp.dest('www/js/dist/')); //gulp sample output [00:39:00] Starting 'ts-compile'... TypeScript error: main.ts(118,30): Error TS2339: Property 'object' does not exist on type 'boolean'. TypeScript error: main.ts(137,24): Error TS2339: Property 'object' does not exist on type 'boolean'. TypeScript error: main.ts(507,44): Error TS2304: Cannot find name 'loading'. [00:39:03] Finished 'ts-compile' after 2.98 s
我通过将tasks.json放入.vscode文件夹解决了这个问题.我最初认为tasks.json会像tsconfig.json(project-root)一样被发现,但事实证明这是错误的.
(编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |