This extension contains code snippets for PayloadCMS.
Installation
In order to install an extension you need to launch the Command Palette (Ctrl + Shift + P or Cmd + Shift + P) and type Extensions.
There you have either the option to show the already installed snippets or install new ones.
Supported languages (file extensions)
JavaScript (.js)
TypeScript (.ts)
Snippets
Below is a list of all available snippets and the triggers of each one. The ⇥ means the TAB key.
Trigger
Content
!pfa→
Create PayloadCMS Array - Field
!pfc→
Create PayloadCMS Checkbox - Field
!pfd→
Create PayloadCMS Date - Field
!pfe→
Create PayloadCMS Email - Field
!pfg→
Create PayloadCMS Group - Field
!pfn→
Create PayloadCMS Number - Field
!pfp→
Create PayloadCMS Point - Field
!pfrg→
Create PayloadCMS Radio Group Field
!pfrho→
Create PayloadCMS Relationship - Has One - Field
!pfrhm→
Create PayloadCMS Relationship - Has Many - Field
!pfrhop→
Create PayloadCMS Relationship - Has One Polymorphic - Field
!pfrhmp→
Create PayloadCMS Relationship - Has Many Polymorphic - Field