Prism prop snippet with expression bodied members

I’ve been working with Prism lately on a project and I’m a big fan of the framework. Unfortunately, the Prism Template Pack – which provides many useful templates like code snippets – doesn’t support Visual Studio 2022 yet. Until that time you can import some of the code snippets yourself into VS 2022. I took the existing code snippet for creating a bindable property and converted it to use expression bodied members, since I’ve started using them extensively lately.

Here’s the gist for the code snippet:

And here’s how it looks in action:

You can import the code snippet in VS 2022 via the Code Snippets Manager from the Tools menu. Hope you found this helpful!

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.