Where can I download / share Intellisense code snippets?
-
I have written a handful of Intellisense code snippets that I would like to upload somewhere so that I can easily get hold of it if I am working on a different computer. It would also be nice to have a look at what code snippets other people use. I thought it would be easy to find some websites that does this, but I have not been able to find any. Do you know of such sites?
-
I have written a handful of Intellisense code snippets that I would like to upload somewhere so that I can easily get hold of it if I am working on a different computer. It would also be nice to have a look at what code snippets other people use. I thought it would be easy to find some websites that does this, but I have not been able to find any. Do you know of such sites?
-
I have written a handful of Intellisense code snippets that I would like to upload somewhere so that I can easily get hold of it if I am working on a different computer. It would also be nice to have a look at what code snippets other people use. I thought it would be easy to find some websites that does this, but I have not been able to find any. Do you know of such sites?
-
You could post them here in the Tips & Tricks section; see the posting guidelines[^] for further details.
Use the best guess
-
Thanks, but this isn't quite what I was looking for. I'm not looking to share and browse pieces of commonly used code (although this is useful and I'm definitely bookmarking that site), I'm looking to share and browse the XML-based code snippets that Visual Studio use to, for instance, turn
propfull
intoprivate int myVar;
public int MyProperty { get { return myVar;} set { myVar = value;} }
So, what I'd like to post is XML like the following:
<?xml version="1.0" encoding="utf-8" ?>
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
<CodeSnippet Format="1.0.0">
<Header>
<Title>propfull</Title>
<Shortcut>propfull</Shortcut>
<Description>Code snippet for property and backing field</Description>
<Author>Microsoft Corporation</Author>
<SnippetTypes>
<SnippetType>Expansion</SnippetType>
</SnippetTypes>
</Header>
<Snippet>
<Declarations>
<Literal>
<ID>type</ID>
<ToolTip>Property type</ToolTip>
<Default>int</Default>
</Literal>
<Literal>
<ID>property</ID>
<ToolTip>Property name</ToolTip>
<Default>MyProperty</Default>
</Literal>
<Literal>
<ID>field</ID>
<ToolTip>The variable backing this property</ToolTip>
<Default>myVar</Default>
</Literal>
</Declarations>
<Code Language="csharp"><![CDATA[private $type$ $field$;public $type$ $property$ { get { return $field$;} set { $field$ = value;} } $end$\]\]> </Code> </Snippet> </CodeSnippet>
</CodeSnippets>