EgretWing loads the plugin by means of inactive load. The activate
method defined by the plugin will be invoked only when the plugin needs to be activated. Through the activationEvents
field of the package.json
of the plugin, a context is provided to indicate when the plugin will be activated. The following activation events are currently supported:
This event will be triggered when the document of corresponding language is opened. For example:
...
"activationEvents": [
"onLanguage:python"
]
...
The event will be triggered when a command command
is executed. For example:
...
"activationEvents": [
"onCommand:extension.sayHello"
]
...
The event will be triggered when the workspace includes the specified file. For example:
...
"activationEvents": [
"workspaceContains:.editorconfig"
]
...
The event will be triggered when EgretWing is started. For example:
...
"activationEvents": [
"*"
]
...