{"id":44476,"date":"2019-06-19T11:21:04","date_gmt":"2019-06-19T18:21:04","guid":{"rendered":"http:\/\/devblogs.microsoft.com\/xamarin\/?p=44476"},"modified":"2019-08-30T08:28:54","modified_gmt":"2019-08-30T15:28:54","slug":"xaml-intellisense-vs4m-xamarin-forms","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/xamarin\/xaml-intellisense-vs4m-xamarin-forms\/","title":{"rendered":"New Xamarin.Forms XAML IntelliSense in Visual Studio for Mac"},"content":{"rendered":"<p>Visual Studio 2019 for Mac version 8.2 is officially <a href=\"https:\/\/devblogs.microsoft.com\/visualstudio\/visual-studio-2019-for-mac-version-8-1-is-now-available-and-a-preview-for-8-2\/\" target=\"_blank\" rel=\"noopener noreferrer\">available as a preview<\/a>. Now featuring significant improvements to the XAML editing experience for Xamarin developers. The Xamarin.Forms XAML editing experience on Mac is now powered by the same engine that drives WPF, UWP, and <a href=\"https:\/\/devblogs.microsoft.com\/xamarin\/new-xamarin-forms-xaml-intellisense-visual-studio-2017\/\" rel=\"noopener noreferrer\" target=\"_blank\">Xamarin.Forms IntelliSense<\/a> on Windows. This brings several enhancements to Xamarin.Forms developers. Enhancements such as improved matching, binding\/commanding IntelliSense, and light bulb suggestions. Additionally, code navigation, linting, resource completion, and markup extension completion also underwent ameliorations.<\/p>\n<h2>XAML IntelliSense Experience<\/h2>\n<p>Improvements to the XAML editing experience were driven by your feedback in numerous surveys and one-on-one interviews. Thank you for continuing to provide our team feedback and shape the future of Xamarin integration in Visual Studio. Keep it coming!<\/p>\n<p>In this blog post, we will look at some of the specific improvements to the XAML editing experience.<\/p>\n<h3>Matching<\/h3>\n<p>As you type, the IntelliSense engine provides suggestions. Unfortunately, if you mistype, or if there are lots of suggestions provided, it can be difficult to find exactly what you need. This release improves the matching around control and property names to ensure you receive the correct suggestion:<\/p>\n<ul>\n<li><strong>Fuzzy Matching<\/strong>: The current matching algorithm only looks for exact string matches. Even a minor mistyping can result in no suggestions. The new algorithm will provide matches, even if you mistype. Example: <code>Stck<\/code> provides a suggestion for <code>StackPanel<\/code>.<\/li>\n<li><strong>Substring Matching<\/strong>: This matching is ideal for scenarios where you know part of the control name, but not the exact name. It\u2019s also useful if you\u2019re looking for groupings of controls. Example: Layout provides suggestions for <code>StackLayout<\/code>, <code>GridLayout<\/code>, <code>RelativeLayout<\/code>, etc.<\/li>\n<li><strong>CamelCase Matching<\/strong>: Shortcuts are provided for CamelCase types. Example: <code>SL<\/code> provides a suggestion for <code>SlackLayout<\/code>.<\/li>\n<\/ul>\n<p><center>\n<div style=\"width: 392px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-44476-1\" width=\"392\" height=\"227\" poster=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/03\/swimlane-xamarin-cross-platform-1.png\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/Matching.mp4?_=1\" \/><a href=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/Matching.mp4\">http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/Matching.mp4<\/a><\/video><\/div>\n<\/center><\/p>\n<h3>Binding Context IntelliSense<\/h3>\n<p>When your binding context is set in XAML (as opposed to the constructor of the code behind), Visual Studio will make suggestions for data binding or commanding:<\/p>\n<p><center>\n<div style=\"width: 380px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-44476-2\" width=\"380\" height=\"240\" poster=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/03\/swimlane-xamarin-cross-platform-1.png\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/BindingContextIntelliSense.mp4?_=2\" \/><a href=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/BindingContextIntelliSense.mp4\">http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/BindingContextIntelliSense.mp4<\/a><\/video><\/div>\n<\/center><\/p>\n<h3>Light Bulb Suggestions<\/h3>\n<p>Now, Visual Studio offers light bulb suggestions for things like missing XML namespace imports:<\/p>\n<p><center>\n<div style=\"width: 516px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-44476-3\" width=\"516\" height=\"111\" poster=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/03\/swimlane-xamarin-cross-platform-1.png\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/LightbulbSuggestion.mp4?_=3\" \/><a href=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/LightbulbSuggestion.mp4\">http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/LightbulbSuggestion.mp4<\/a><\/video><\/div>\n<\/center><\/p>\n<h3>Resource IntelliSense<\/h3>\n<p>Edited resources defined in the page will be available to the IntelliSense service to provide suggestions:<\/p>\n<p><center>\n<div style=\"width: 476px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-44476-4\" width=\"476\" height=\"239\" poster=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/03\/swimlane-xamarin-cross-platform-1.png\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/ResourceIntelliSense.mp4?_=4\" \/><a href=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/ResourceIntelliSense.mp4\">http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/ResourceIntelliSense.mp4<\/a><\/video><\/div>\n<\/center><\/p>\n<h3>Markup Extension IntelliSense<\/h3>\n<p>Markup extensions, such as Binding, StaticResource, or x:Static, will now appear after opening a curly brace:<\/p>\n<p><center>\n<img decoding=\"async\" class=\"alignnone size-medium wp-image-44496\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/Markup-Extension-300x194.png\" alt=\"\" width=\"300\" height=\"194\" srcset=\"https:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/Markup-Extension-300x194.png 300w, https:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/Markup-Extension-768x497.png 768w, https:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/Markup-Extension.png 796w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/>\n<\/center><\/p>\n<h3>XML Namespace IntelliSense<\/h3>\n<p>Additionally, Visual Studio will also provide suggestions when editing an XML namespace:<\/p>\n<p><center>\n<div style=\"width: 464px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-44476-5\" width=\"464\" height=\"182\" poster=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/03\/swimlane-xamarin-cross-platform-1.png\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/ViewModel.mp4?_=5\" \/><a href=\"http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/ViewModel.mp4\">http:\/\/devblogs.microsoft.com\/xamarin\/wp-content\/uploads\/sites\/44\/2019\/06\/ViewModel.mp4<\/a><\/video><\/div>\n<\/center><\/p>\n<h3>Share your feedback!<\/h3>\n<p>To make sure XAML IntelliSense for Xamarin.Forms inside of VS2019 for Mac is everything you hope for, we need your help! Let us know if you experience problems with any functionality detailed above, or if you have expectations that aren\u2019t being met. Do this by using the reporting feature in the IDE, which can be found under <strong>Help &gt; Report a Problem<\/strong>.<\/p>\n<p>With your feedback, please provide a sample XAML file, video, and\/or reproduction steps, if possible. Thank you for help making improvements to Xamarin tooling in Visual Studio and Visual Studio for Mac!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Visual Studio 2019 for Mac version 8.2 is now available as a preview, featuring significant improvements to the XAML editing experience for Xamarin developers. The Xamarin.Forms XAML editing experience on Mac is now powered by the same engine that drives WPF, UWP, and Xamarin.Forms IntelliSense on Windows. Learn More!<\/p>\n","protected":false},"author":546,"featured_media":44518,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[2,367],"tags":[5842,5843,16,5841],"class_list":["post-44476","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-developers","category-xamarin-forms","tag-intellisense","tag-visual-studio-for-mac","tag-xamarin-forms","tag-xaml"],"acf":[],"blog_post_summary":"<p>Visual Studio 2019 for Mac version 8.2 is now available as a preview, featuring significant improvements to the XAML editing experience for Xamarin developers. The Xamarin.Forms XAML editing experience on Mac is now powered by the same engine that drives WPF, UWP, and Xamarin.Forms IntelliSense on Windows. Learn More!<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/posts\/44476","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/users\/546"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/comments?post=44476"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/posts\/44476\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/media\/44518"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/media?parent=44476"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/categories?post=44476"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/xamarin\/wp-json\/wp\/v2\/tags?post=44476"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}