Skip to content

Instantly share code, notes, and snippets.

@lcaballero
Created March 5, 2012 07:45
Show Gist options
  • Save lcaballero/1977339 to your computer and use it in GitHub Desktop.
Save lcaballero/1977339 to your computer and use it in GitHub Desktop.
Visual Studio snippet xml that expands and surrounds with the typical jQuery closure plug-in like syntax.
<CodeSnippet Format="1.1.0" xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
<!-- JS surround with closure Snippet -->
<Header>
<Title>closure</Title>
<Author>Lucas Caballero</Author>
<Shortcut>jqclosure</Shortcut>
<Description>Surround/Expand with the typeical jQuery closure plug-in syntax.</Description>
<SnippetTypes>
<SnippetType>Expansion</SnippetType>
<SnippetType>SurroundsWith</SnippetType>
</SnippetTypes>
</Header>
<Snippet>
<Declarations>
<Literal>
<ID>selected</ID>
<ToolTip>content</ToolTip>
<Default></Default>
</Literal>
</Declarations>
<Code Language="jscript">
<![CDATA[;(function($$){
$selected$$end$
})(jQuery);]]></Code>
</Snippet>
</CodeSnippet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment