为什么我的 VS 2013 ASP.NET 项目属性中缺少 Typescript 设置选项卡? [英] Why is the Typescript settings tab missing in my VS 2013 ASP.NET project properties?

查看:15
本文介绍了为什么我的 VS 2013 ASP.NET 项目属性中缺少 Typescript 设置选项卡?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将一些 javascript 文件迁移到旧版 ASP.NET MVC 5 项目中的 Typescript.一世我已经创建了一个 Typescript 文件,并且从 TS 到 JS 的编译按预期工作,但是我的旧项目的属性中没有Typescript Build"选项卡.

I'm trying to migrate some javascript files to Typescript in a legacy ASP.NET MVC 5 project. I I've created a Typescript file and the compilation from TS to JS works as expected, but I there is no "Typescript Build" Tab in my legacy project's properties.

我在处理一个新的 ASP.NET MVC 5 项目时没有遇到这个问题.如何在我的遗留项目中解决这个问题?我使用的是 Visual Studio 2013 更新 1.

I did not have this problem when working on a new ASP.NET MVC 5 project. How can I fix this in my legacy project? I am using Visual Studio 2013 Update 1.

谢谢,

阿德里安

推荐答案

我需要将以下行添加到 csproj 以导入打字稿目标:

I needed to add the following line to the csproj to import the typescript targets:

<Import Project="$(MSBuildExtensionsPath32)MicrosoftVisualStudiov$(VisualStudioVersion)TypeScriptMicrosoft.TypeScript.targets" Condition="Exists('$(MSBuildExtensionsPath32)MicrosoftVisualStudiov$(VisualStudioVersion)TypeScriptMicrosoft.TypeScript.targets')" />

然后我可以在项目设置中看到打字稿构建选项.

Then I could see the typescript build options in the project settings.

这篇关于为什么我的 VS 2013 ASP.NET 项目属性中缺少 Typescript 设置选项卡?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆