Skip to content

Instantly share code, notes, and snippets.

@sharwell
Created April 19, 2013 15:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sharwell/5421032 to your computer and use it in GitHub Desktop.
Save sharwell/5421032 to your computer and use it in GitHub Desktop.
Simple example to export the `ContentTypeDefinition`
using System.ComponentModel.Composition;
using Microsoft.VisualStudio.Utilities;
public static class ExampleDefinitions
{
/* The language name (used for the language service) and content type must be the same
* due to the way Visual Studio internally registers file extensions and content types.
*/
[Export]
[Name("Example")]
[BaseDefinition("code")]
private static readonly ContentTypeDefinition ExampleContentTypeDefinition;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment