Vault.on(‘create’) method
Called when a file is created. This is also called when the vault is first loaded for each existing file If you do not wish to receive create events on vault load, register your event handler inside Workspace.onLayoutReady().
Signature:
on(name: 'create', callback: (file: TAbstractFile) => any, ctx?: any): EventRef;
Parameters
Parameter | Type | Description |
---|---|---|
name | ’create’ | |
callback | (file: TAbstractFile ) ⇒ any | |
ctx | any | (Optional) |
Returns: