Vscode - How do I constrain some snippets to blank files only?

147 views Asked by At

I am creating some snippets to .tex files. However, I would like some of these snippets to appear only if my document is blank/empty.

It is possible to create a conditional to check it? It would be something like that:

"Example": {
  "prefix": "ex",
  "body": [
    "Just one example"
  ],
  "description": "Example",
  "conditional": if-is-a-blank-file
}

Obviously, "conditional" is just a pretend. Thanks in advance.

0

There are 0 answers