Ask Learn
Preview
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign inThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
If you are building a VSTS (or TFS) web extension, be aware of the breaking changes that come from the new SDK version.
Last week a we pushed a new release of the SDK (vss-web-extension-sdk@1.108.0). This release comes with some important dependency updates:
If your extension was built using typescript, you may experience build problems when you update to this new version. Let's see how to handle these problems:
NOTE: The way that you will handle this will depend if you're using TypeScript Definition (tsd) or typing.
We suffered a little bit with this update. As you can see in our open source extensions, most of our extensions use the Visual Studio project template for VSTS extensions. It is a Visual Studio project template that comes with all common files needed to build VSTS extensions. It's a good jump start. But, as it is a Visual Studio project, it uses MSBuild and its targets to build the code. It depends on the TypeScript for Visual Studio package, that installs all MSBuild targets and TypeScript libraries. Even if you include a dependency for TypeScript in you code through a NPM package, MSBuild won't use it. It will look for the TypeScript binaries and libraries at the default TypeScript for Visual Studio installation path (C:\Program Files (x86) \Microsoft SDKs\TypeScript).
Ok, but what is the problem? Well, we use a VSTS hosted build agent to build our extensions, and the hosted build doesn't have the latest version of TypeScript for Visual Studio installed, yet (at the time this post are written). So, some of our builds started to fail after the update.
It took some time for us to discover this issue. We preferred not to wait and not to be dependent on a hosted build agent update. So we changed our build scripts to be more robust after this event.
Extensions for Visual Studio Team Services and Team Foundation Server
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign in