Create your own snippets in VSCode , Boilerplate in VS code


What is a Boilerplate?

In computer programming, boilerplate code or just boilerplate are sections of code that are repeated in multiple places with little to no variation. When using languages that are considered verbose, the programmer must write a lot of code to accomplish only minor functionality. Such code is called boilerplate.

How can you create your own Boilerplate in VS code?

we are going to create C Program  boilerplate in VS code 

  • At first, open vs code and than got to setting 
  • Click User snippets
  • Now remove the comment out (//) from the code, select from the eample.


  • Now replace the code, with our boilerplate




  • or you can also copy the code and paste it there.
"boilerplate": {
        "prefix": "boilerplate code",
        "body": [
            "#include <stdio.h>",
            "#include <conio.h>",
            "int main(){",
            "return 0;",
            "}"
        ],
        "description": "Log output to console"code-box

  • now save it by pressing Ctrl+s 
  •  open a new terminal and type "boi" and hit the tab button. 
  • your boilerplate is ready




disclaimer! This article for tech updates, not promoted by any company, if any copyright post is there, means that's with proper credits in there. Helps us to grow more by allowing the notification and subscribing by email! #suspensecreator

Post a Comment

To be published, comments must be reviewed by the administrator *

Previous Post Next Post
Post ADS 1
Post ADS 1