providing_live_templates.md: use snippet for EP with link to IPE

This commit is contained in:
Yann Cébron 2025-03-19 16:32:30 +01:00
parent 8206d2db22
commit f8c3d99995

View File

@ -103,7 +103,7 @@ Depending on the version of the IntelliJ Platform, different steps are used to c
<tab title="2022.3 and later"> <tab title="2022.3 and later">
Using the `com.intellij.defaultLiveTemplates` and `com.intellij.liveTemplateContext` extension points, register the implementations with the IntelliJ Platform. Using the <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.defaultLiveTemplates"/></include> and <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.liveTemplateContext"/></include>, register the implementations with the IntelliJ Platform.
The `file` attribute in <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.defaultLiveTemplates"/></include> specifies `path/filename` under the <path>src/main/resources</path> folder. The `file` attribute in <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.defaultLiveTemplates"/></include> specifies `path/filename` under the <path>src/main/resources</path> folder.
Specify required `contextId` attribute in <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.liveTemplateContext"/></include> instead of [`TemplateContextType`](%gh-ic%/platform/analysis-api/src/com/intellij/codeInsight/template/TemplateContextType.java) constructor (existing declarations will continue working). Specify required `contextId` attribute in <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.liveTemplateContext"/></include> instead of [`TemplateContextType`](%gh-ic%/platform/analysis-api/src/com/intellij/codeInsight/template/TemplateContextType.java) constructor (existing declarations will continue working).
@ -121,7 +121,7 @@ Specify required `contextId` attribute in <include from="snippets.topic" element
<tab title="Versions since 2020.1 till 2022.3"> <tab title="Versions since 2020.1 till 2022.3">
Using the `com.intellij.defaultLiveTemplates` and `com.intellij.liveTemplateContext` extension points, register the implementations with the IntelliJ Platform. Using the <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.defaultLiveTemplates"/></include> and <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.liveTemplateContext"/></include>, register the implementations with the IntelliJ Platform.
The `file` attribute in the <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.defaultLiveTemplates"/></include> specifies `path/filename` under the <path>src/main/resources</path> folder. The `file` attribute in the <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.defaultLiveTemplates"/></include> specifies `path/filename` under the <path>src/main/resources</path> folder.
```xml ```xml
@ -159,7 +159,7 @@ final class MarkdownTemplateProvider implements DefaultLiveTemplatesProvider {
} }
``` ```
Using the `com.intellij.defaultLiveTemplatesProvider` and `com.intellij.liveTemplateContext` extension points, register the implementations with the IntelliJ Platform. Using the <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.defaultLiveTemplates"/></include> and <include from="snippets.topic" element-id="ep"><var name="ep" value="com.intellij.liveTemplateContext"/></include>, register the implementations with the IntelliJ Platform.
```xml ```xml
<extensions defaultExtensionNs="com.intellij"> <extensions defaultExtensionNs="com.intellij">