I try to create multilines snippet like so:
"mySnippet": {
"prefix": "test",
"body": [
"<div>",
"<p></p>",
"</div>"
]
}
But it's not indented...
Reading the doc doesnt' help
I try to create multilines snippet like so:
"mySnippet": {
"prefix": "test",
"body": [
"<div>",
"<p></p>",
"</div>"
]
}
But it's not indented...
Reading the doc doesnt' help
You need to add the indentation inside the second string element of the body array:
"mySnippet": {
"prefix": "test",
"body": [
"<div>",
" <p></p>",
"</div>"
]
}
You can use the \tfor TAB on each line:
"table": {
"prefix": "table",
"body": [
"<table cellspacing=\"0\" cellpadding=\"0\">",
"\t<tr>",
"\t\t<td>",
"\t\t\t<i class=\"fas fa-bullhorn\"></i>",
"\t\t</td>",
"\t\t<td>",
"\t\t\t${1:element}",
"\t\t</td>",
"\t</tr>",
"</table>"
],
"description": "Text with a bullhorn icon on the left"
}