Google closure template full file support (.soy)

Add full file support for .soy files. See section below. :)

Functionality

  • Syntax highlight
  • Syntax check: inline error and warning underline
  • Go to definition support
  • Snippets

Syntax highlight

  • Highlights keywords, variables and so :)

Go To Definition

  • Go to definion of given template with F12 / ctrl+click

Error highlights

  • Missing $ sign in variable declarations
  • Missing closing tag for let declarations and params
  • Extra space before closing tag for lets and params
  • Unnecessary / character for let and param blocks
  • Self closing for templates and deltemplates

Warning highlights

  • TODO comments
  • Breaking Change comments

Bracket closing pair autoinsertion

Snippets

All snippets start with the character s to be able to quickly search for them.

Snippets:

  • sfor - foreach block
  • sif - if block
  • sife - if-else block
  • sl - let statement - single line
  • slb - let statement - block
  • sp - param statement - single line
  • spb - param statement - block
  • sps - param signature
  • sc - call block
  • sdelc - delcall block
  • sdelcempty - delcall block with allowemptydefault="true"
  • stemp - template skeleton
  • sdeltemp - deltemplate skeleton