{"id":234400,"date":"2021-09-09T09:00:09","date_gmt":"2021-09-09T16:00:09","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/visualstudio\/?p=234400"},"modified":"2021-09-09T09:45:20","modified_gmt":"2021-09-09T16:45:20","slug":"the-future-of-visual-studio-extensibility-is-here","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/visualstudio\/the-future-of-visual-studio-extensibility-is-here\/","title":{"rendered":"The Future of Visual Studio Extensibility is Here!"},"content":{"rendered":"<p>Visual Studio 2022 seeks to greatly improve your overall development experience, and we&#8217;re moving forward with that journey in improving VS extension writing and usage today!\u00a0 We have several exciting extensibility updates that are either available now or on the horizon, so let&#8217;s check them out!<\/p>\n<p>&nbsp;<\/p>\n<h3>Bookmark the new VSExtensibility GitHub repository<\/h3>\n<p>With so many extensibility developments (many of which are still in preview), we needed a hub to contain it all!\u00a0 We\u2019ve created a public <a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\">VSExtensibility repo<\/a> (or <a href=\"https:\/\/aka.ms\/vsextensibilityupdates\">aka.ms\/vsextensibilityupdates<\/a>) as your go-to destination for upcoming extension-related announcements, code samples, and documentation on preview features. The docs and code samples will evolve and migrate to official Microsoft documentation as we iterate on our extensibility projects.\u00a0 Keep an eye on the repo for regular updates!<\/p>\n<p>&nbsp;<\/p>\n<h3>Using extensions in Visual Studio 2022<\/h3>\n<p>For many of you, having your ideal, 64-bit Visual Studio 2022 experience is not complete without the extensions that are essential to your development environment.\u00a0 If you\u2019re an existing extension author, you\u2019ll need to successfully migrate your extension to be VS 2022-compatible using the <a href=\"https:\/\/docs.microsoft.com\/en-us\/visualstudio\/extensibility\/migration\/update-visual-studio-extension?view=vs-2022\">VS 2022 extension migration guidance<\/a>.\u00a0 Many popular extensions such as <a href=\"https:\/\/marketplace.visualstudio.com\/items?itemName=DevExpress.CodeRushforVS2022\">CodeRush<\/a>, <a href=\"https:\/\/marketplace.visualstudio.com\/items?itemName=JaredParMSFT.VsVim2022Preview\">VSVim<\/a>, <a href=\"https:\/\/marketplace.visualstudio.com\/items?itemName=VisualStudioPlatformTeam.ProductivityPowerPack2022\">Productivity Power Tools<\/a>, and most <a href=\"https:\/\/marketplace.visualstudio.com\/search?term=mads&amp;target=VS&amp;category=All%20categories&amp;vsVersion=vs2022&amp;sortBy=Relevance\">Mads Kristensen extensions<\/a> are available now, and there will be more to come as we approach VS 2022\u2019s official release.<\/p>\n<p><figure id=\"attachment_234409\" aria-labelledby=\"figcaption_attachment_234409\" class=\"wp-caption aligncenter\" ><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/vs2022-marketplace.png\"><img decoding=\"async\" class=\"size-full wp-image-234409\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/vs2022-marketplace.png\" alt=\"Image vs2022 marketplace\" width=\"916\" height=\"558\" srcset=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/vs2022-marketplace.png 916w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/vs2022-marketplace-300x183.png 300w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/vs2022-marketplace-768x468.png 768w\" sizes=\"(max-width: 916px) 100vw, 916px\" \/><\/a><figcaption id=\"figcaption_attachment_234409\" class=\"wp-caption-text\">Visual Studio 2022 extensions on VS Marketplace<\/figcaption><\/figure><\/p>\n<p>&nbsp;<\/p>\n<h3>Expand Language Server Protocol (LSP)<\/h3>\n<p>We are now offering extensions to the Language Server Protocol functionalities which let you leverage capabilities specific to Visual Studio.\u00a0 Servers can use these additional contracts to provide additional functionalities such as diagnostics info and project contexts when communicating with a Visual Studio instance.<\/p>\n<p>To get started, check out the <a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\/blob\/main\/docs\/lsp\/lsp-extensions-specifications.md\">LSP extension documentation<\/a> and <a href=\"https:\/\/www.nuget.org\/packages\/Microsoft.VisualStudio.LanguageServer.Protocol.Extensions\">download the related NuGet package<\/a>.<\/p>\n<p>&nbsp;<\/p>\n<h3>Easier extension writing with the Visual Studio Community Toolkit<\/h3>\n<p>One of the biggest hurdles to writing a VS extension is that they can be hard to write, especially when you\u2019re just starting out.\u00a0 We\u2019ve heard from authors and aspiring authors that this is due to numerous factors, including hard-to-discover, dated APIs, inconsistent, inaccurate documentation, and lack of best extensibility practices.<\/p>\n<p>To tackle this issue, we have created the Visual Studio Community Toolkit.\u00a0 This toolkit is a community-driven set of project templates, API wrappers, and productivity tools that provide a simpler, streamlined experience for writing extensions in Visual Studio.<\/p>\n<p><figure id=\"attachment_234408\" aria-labelledby=\"figcaption_attachment_234408\" class=\"wp-caption aligncenter\" ><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-templates.png\"><img decoding=\"async\" class=\" wp-image-234408\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-templates.png\" alt=\"Image toolkit templates\" width=\"692\" height=\"450\" srcset=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-templates.png 624w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-templates-300x195.png 300w\" sizes=\"(max-width: 692px) 100vw, 692px\" \/><\/a><figcaption id=\"figcaption_attachment_234408\" class=\"wp-caption-text\">VS Community Toolkit Project Templates<\/figcaption><\/figure><\/p>\n<p>&nbsp;<\/p>\n<p><figure id=\"attachment_234406\" aria-labelledby=\"figcaption_attachment_234406\" class=\"wp-caption aligncenter\" ><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-insert-guid.png\"><img decoding=\"async\" class=\"size-full wp-image-234406\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-insert-guid.png\" alt=\"Image toolkit insert guid\" width=\"921\" height=\"415\" srcset=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-insert-guid.png 921w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-insert-guid-300x135.png 300w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-insert-guid-768x346.png 768w\" sizes=\"(max-width: 921px) 100vw, 921px\" \/><\/a><figcaption id=\"figcaption_attachment_234406\" class=\"wp-caption-text\">Extension command written with the VS Community Toolkit<\/figcaption><\/figure><\/p>\n<p>&nbsp;<\/p>\n<p><figure id=\"attachment_234405\" aria-labelledby=\"figcaption_attachment_234405\" class=\"wp-caption aligncenter\" ><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-icon-intellisense.png\"><img decoding=\"async\" class=\"size-full wp-image-234405\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-icon-intellisense.png\" alt=\"Image toolkit icon intellisense\" width=\"624\" height=\"163\" srcset=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-icon-intellisense.png 624w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-icon-intellisense-300x78.png 300w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption id=\"figcaption_attachment_234405\" class=\"wp-caption-text\">VS Community Toolkit Icon IntelliSense<\/figcaption><\/figure><\/p>\n<p>&nbsp;<\/p>\n<p><figure id=\"attachment_234407\" aria-labelledby=\"figcaption_attachment_234407\" class=\"wp-caption aligncenter\" ><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-intellisense-command-placement.png\"><img decoding=\"async\" class=\"size-full wp-image-234407\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-intellisense-command-placement.png\" alt=\"Image toolkit intellisense command placement\" width=\"936\" height=\"540\" srcset=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-intellisense-command-placement.png 936w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-intellisense-command-placement-300x173.png 300w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/toolkit-intellisense-command-placement-768x443.png 768w\" sizes=\"(max-width: 936px) 100vw, 936px\" \/><\/a><figcaption id=\"figcaption_attachment_234407\" class=\"wp-caption-text\">Full, visual IntelliSense for extension command placement<\/figcaption><\/figure><\/p>\n<p>&nbsp;<\/p>\n<h4><em>How do I get started with the Community Toolkit?<\/em><\/h4>\n<p>The recommended way to get started is to head on over to the <a href=\"https:\/\/www.vsixcookbook.com\/\">VSIX Cookbook<\/a> and follow the guide. There\u2019s lots of easy-to-follow tutorials, videos, and code samples to get you going.\u00a0 The best part about the Community Toolkit is the community! If there are additional scenarios you\u2019d like to see added to the toolkit, you can contribute to and provide feedback for the Community Toolkit and other open-source projects by checking out the <a href=\"https:\/\/github.com\/VsixCommunity\/\">VSIX Community org on GitHub<\/a>.<\/p>\n<p>&nbsp;<\/p>\n<h3>Write securer, more reliable extensions with the new, Out-of-Proc Extensibility Model<\/h3>\n<p>Extensions crashing VS.\u00a0 Lack of secure extensions.\u00a0 Inconsistent documentation.\u00a0 Having to restart VS when installing extensions.\u00a0 These are some of the most common frustrations extension users and writers have expressed in the past few years.\u00a0 Compared to the current model, the new extensibility model loads extensions out-of-process.\u00a0 This allows for more reliable extensions that won\u2019t cause Visual Studio to hang or crash.\u00a0 Like the Community Toolkit, this new model will make extensions easier to write with more cohesive APIs and documentation.\u00a0 Also, extensions written with the out-of-proc model let you install them without restarting VS. Last but not least, these extensions can be placed in low-trust environments, protecting your dev machine.<\/p>\n<h4><em>What can I do with the new extensibility model in Phase 1?<\/em><\/h4>\n<p>Phase 1 allows you to write and F5-debug out-of-proc, command-focused extensions working with open documents such as single-file linters and formatters using the new model&#8217;s editor API.\u00a0 Writing linter extensions such as spell checkers provides your users with diagnostic info in the VS editor via squiggles and error list entries.\u00a0 Writing a formatter extension lets your users easily &#8220;prettify&#8221; or format their code.\u00a0 Publishing out-of-proc extensions to the VS Marketplace is still to come!<\/p>\n<p><figure id=\"attachment_234404\" aria-labelledby=\"figcaption_attachment_234404\" class=\"wp-caption aligncenter\" ><a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/linter-example.png\"><img decoding=\"async\" class=\"size-full wp-image-234404\" src=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/linter-example.png\" alt=\"Image linter example\" width=\"624\" height=\"425\" srcset=\"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/linter-example.png 624w, https:\/\/devblogs.microsoft.com\/visualstudio\/wp-content\/uploads\/sites\/4\/2021\/09\/linter-example-300x204.png 300w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/a><figcaption id=\"figcaption_attachment_234404\" class=\"wp-caption-text\">Example linter extension in Tools window using out-of-proc model<\/figcaption><\/figure><\/p>\n<p>&nbsp;<\/p>\n<h4><em>Is the current extensibility model being deprecated?<\/em><\/h4>\n<p>No!\u00a0 Continue using the current model for any VS 2022 extensions that will be distributed to users and\/or published in the VS Marketplace.<\/p>\n<h4><em>How do I get started with the out-of-proc model?<\/em><\/h4>\n<p>The new extensibility model is a long, ongoing project. As a result, it won&#8217;t be available at full feature parity and general consumption by the end of VS 2022\u2019s release cycle. Whether you\u2019re new to writing extensions or you\u2019re an extension-writing pro, we encourage you to <a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\/blob\/main\/docs\/new-extensibility-model\/getting-started\/create-your-first-extension.md\">try writing an extension using the new model<\/a> and share your feedback under <a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\/issues\">Issues in the VSExtensibility repository<\/a>!<\/p>\n<p>&nbsp;<\/p>\n<h3>There are so many updates!\u00a0 Where and when should I use each one?<\/h3>\n<p>Overwhelmed by all the new extensibility additions and not sure which one(s) you should use?\u00a0 Ask yourself the following questions:<\/p>\n<h4><em>How do I make sure my extension is compatible with Visual Studio 2022?<\/em><\/h4>\n<p>Follow the <a href=\"https:\/\/docs.microsoft.com\/en-us\/visualstudio\/extensibility\/migration\/update-visual-studio-extension?view=vs-2022\">migration guidance<\/a> to make sure your audience can use their essential extensions in VS 2022.<\/p>\n<h4><em>How can I expand LSP functionality in my projects?<\/em><\/h4>\n<p>Check out the <a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\/blob\/main\/docs\/lsp\/lsp-extensions-specifications.md\">new expansion options for LSP<\/a> when communicating between servers and VS instances.<\/p>\n<h4><em>Extensions are difficult and tedious to write! What tools can help make the experience easier?<\/em><\/h4>\n<p>Install and use the <a href=\"https:\/\/www.vsixcookbook.com\/getting-started\/get-the-tools.html\">Visual Studio Community Toolkit<\/a>!<\/p>\n<h4><em>I\u2019m feeling experimental and want to share my feedback on the future of extension writing.\u00a0 What should I do?<\/em><\/h4>\n<p><a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\/blob\/main\/docs\/new-extensibility-model\/getting-started\/oop-extensibility-model-overview.md\">Try out phase 1 of the out-of-proc extensibility model!<\/a><\/p>\n<h4><em>How do I keep track of all these ongoing extensibility developments?\u00a0<\/em><\/h4>\n<p>Bookmark the <a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\">VSExtensibility repo (aka.ms\/vsextensibilityupdates)<\/a>, your hub for all upcoming extensibility-related announcements.\u00a0 As we embark on this journey toward an improved extensibility experience, don\u2019t forget to share your feedback under<a href=\"https:\/\/github.com\/microsoft\/VSExtensibility\/issues\"> Issues<\/a>!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Visual Studio 2022 seeks to greatly improve your overall development experience, and we&#8217;re moving forward with that journey in improving VS extension writing and usage today!\u00a0 We have several exciting extensibility updates that are either available now or on the horizon, so let&#8217;s check them out!<\/p>\n","protected":false},"author":651,"featured_media":234300,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1388,155],"tags":[294,12,6815],"class_list":["post-234400","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-extensibility","category-visual-studio","tag-extensions","tag-visual-studio","tag-visual-studio-2022"],"acf":[],"blog_post_summary":"<p>Visual Studio 2022 seeks to greatly improve your overall development experience, and we&#8217;re moving forward with that journey in improving VS extension writing and usage today!\u00a0 We have several exciting extensibility updates that are either available now or on the horizon, so let&#8217;s check them out!<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/posts\/234400","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/users\/651"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/comments?post=234400"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/posts\/234400\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/media\/234300"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/media?parent=234400"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/categories?post=234400"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/visualstudio\/wp-json\/wp\/v2\/tags?post=234400"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}