Adding new Snippets
The Welkin Suite offers you wide range of the predefined code snippets, but you are able to add as many your own custom snippets as you want.
There are two ways how you can add new snippets.
Adding snippets manually
- Navigate to TWS installation directory (it could be at the disk C: for example),
- open the
Extensions\Application\Editor\CodeSnippets\Snippets
folder, - create a text file with the extension
.snippet
(for example CustomSnippet.snippet), - save the file.
While this way doesn't require any additional actions, it may result in some conflicts if on a new version update, The Welkin Suite includes a snippet with the same name in one of the new versions.
Adding the snippets via the Code Snippets Manager
The steps for creating your own new snippet are the following:
- create a separate folder on your computer (for example create a folder named
Snippets
in theDocuments\The Welkin Suite
folder), - create a text file with the extension
.snippet
(for example CustomSnippet.snippet), - save the file.
Now the snippet is ready, but you need to add it to The Welkin Suite before using it. Open the Code Snippets Manager (Main Menu: Tools ⇒ Code Snippet manager
or the Ctrl+K, Ctrl+B hotkey), click the Add button and select the folder that was created in the previous steps.
The folder is now added to the Code Snippet Manager and the snippets, which are located into it, are present along with their details. To finish click the OK button.
Finally, your snippet(s) are ready for use in the same way as the default ones.
In this section: |
This also may be useful: |