
Google Analytics Snippet Pack
About
Google Analytics Snippet Pack for Visual Studio helps you write global site tag (gtag.js) code that allows you to send event data to Google Analytics. Due to the nature of this extension, you will find these snippets in HTML and JavaScript Google Analytics Snippet Pack is compatible right from Visual Studio 2012 to 2019 (Community, Professional and Enterprise).
The Google Analytics Snippet extends the code snippet manager of Visual Studio and allows you to insert code snippets into your editor. To insert snippets for the language you're currently writing in your editor, you can use the shortcut keys CTRL+K CTRL+X and then find Google Analytics Snippet as a folder. Alternatively, to bring up the code snippet manager, use the shortcut keys CTRL+K CTRL+B.
How to get it
Download the Google Analytics Snippet from the Visual Studio Marketplace or install directly from Visual Studio by searching for 'Google Analytics Snippet' in the 'Extensions and Updates' window.
Feedback
Should you find any features/snippets missing in Google Analytics Snippet, feel free to create a new issue on GitHub here and let me know what you’re after and I can include that in the product backlog for next releases. P.S. Please search existing issues first before creating a new one. 😃
Special thanks to the Snippet Pack Project Template by Mads Kristensen for making it easier to create a new snippet pack and providing a really helpful explanation.