@intlayer/docs 8.5.0 → 8.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. package/docs/ar/dictionary/html.md +10 -3
  2. package/docs/ar/dictionary/markdown.md +15 -17
  3. package/docs/ar/intlayer_with_analog.md +8 -14
  4. package/docs/ar/intlayer_with_vite+lit.md +8 -57
  5. package/docs/ar/intlayer_with_vite+vue.md +3 -3
  6. package/docs/bn/intlayer_with_vite+lit.md +8 -57
  7. package/docs/cs/intlayer_with_vite+lit.md +8 -57
  8. package/docs/de/compiler.md +6 -1
  9. package/docs/de/configuration.md +12 -9
  10. package/docs/de/dictionary/html.md +11 -8
  11. package/docs/de/dictionary/markdown.md +17 -23
  12. package/docs/de/intlayer_with_analog.md +8 -14
  13. package/docs/de/intlayer_with_vite+lit.md +8 -57
  14. package/docs/de/intlayer_with_vite+vue.md +3 -3
  15. package/docs/en/compiler.md +2 -0
  16. package/docs/en/configuration.md +8 -8
  17. package/docs/en/dictionary/html.md +12 -9
  18. package/docs/en/dictionary/markdown.md +18 -24
  19. package/docs/en/intlayer_with_analog.md +8 -14
  20. package/docs/en/intlayer_with_vite+lit.md +10 -57
  21. package/docs/en/intlayer_with_vite+vue.md +13 -3
  22. package/docs/en-GB/dictionary/html.md +10 -3
  23. package/docs/en-GB/dictionary/markdown.md +16 -18
  24. package/docs/en-GB/intlayer_with_analog.md +8 -14
  25. package/docs/en-GB/intlayer_with_vite+lit.md +10 -57
  26. package/docs/en-GB/intlayer_with_vite+vue.md +3 -3
  27. package/docs/es/compiler.md +6 -1
  28. package/docs/es/configuration.md +12 -9
  29. package/docs/es/dictionary/html.md +11 -8
  30. package/docs/es/dictionary/markdown.md +18 -24
  31. package/docs/es/intlayer_with_analog.md +8 -14
  32. package/docs/es/intlayer_with_vite+lit.md +8 -57
  33. package/docs/es/intlayer_with_vite+vue.md +3 -3
  34. package/docs/fr/compiler.md +8 -3
  35. package/docs/fr/configuration.md +12 -9
  36. package/docs/fr/dictionary/html.md +11 -8
  37. package/docs/fr/dictionary/markdown.md +18 -24
  38. package/docs/fr/intlayer_with_analog.md +8 -14
  39. package/docs/fr/intlayer_with_vite+lit.md +8 -57
  40. package/docs/fr/intlayer_with_vite+vue.md +3 -3
  41. package/docs/hi/dictionary/html.md +10 -3
  42. package/docs/hi/dictionary/markdown.md +17 -19
  43. package/docs/hi/intlayer_with_analog.md +8 -14
  44. package/docs/hi/intlayer_with_vite+lit.md +8 -57
  45. package/docs/hi/intlayer_with_vite+vue.md +3 -3
  46. package/docs/id/dictionary/html.md +10 -3
  47. package/docs/id/dictionary/markdown.md +17 -19
  48. package/docs/id/intlayer_with_analog.md +8 -14
  49. package/docs/id/intlayer_with_vite+lit.md +8 -57
  50. package/docs/id/intlayer_with_vite+vue.md +3 -3
  51. package/docs/it/compiler.md +8 -3
  52. package/docs/it/configuration.md +12 -9
  53. package/docs/it/dictionary/html.md +11 -8
  54. package/docs/it/dictionary/markdown.md +18 -24
  55. package/docs/it/intlayer_with_analog.md +8 -14
  56. package/docs/it/intlayer_with_vite+lit.md +8 -57
  57. package/docs/it/intlayer_with_vite+vue.md +3 -3
  58. package/docs/ja/dictionary/html.md +11 -8
  59. package/docs/ja/dictionary/markdown.md +21 -24
  60. package/docs/ja/intlayer_with_analog.md +8 -14
  61. package/docs/ja/intlayer_with_vite+lit.md +8 -57
  62. package/docs/ja/intlayer_with_vite+vue.md +3 -3
  63. package/docs/ko/dictionary/html.md +11 -8
  64. package/docs/ko/dictionary/markdown.md +18 -24
  65. package/docs/ko/intlayer_with_analog.md +8 -14
  66. package/docs/ko/intlayer_with_vite+lit.md +8 -57
  67. package/docs/ko/intlayer_with_vite+vue.md +3 -3
  68. package/docs/nl/intlayer_with_vite+lit.md +8 -57
  69. package/docs/pl/dictionary/html.md +11 -8
  70. package/docs/pl/dictionary/markdown.md +18 -24
  71. package/docs/pl/intlayer_with_analog.md +8 -14
  72. package/docs/pl/intlayer_with_vite+lit.md +8 -57
  73. package/docs/pl/intlayer_with_vite+vue.md +3 -3
  74. package/docs/pt/compiler.md +7 -2
  75. package/docs/pt/configuration.md +11 -9
  76. package/docs/pt/dictionary/html.md +11 -8
  77. package/docs/pt/dictionary/markdown.md +18 -24
  78. package/docs/pt/intlayer_with_analog.md +8 -14
  79. package/docs/pt/intlayer_with_vite+lit.md +8 -57
  80. package/docs/pt/intlayer_with_vite+vue.md +3 -3
  81. package/docs/ru/dictionary/html.md +11 -8
  82. package/docs/ru/dictionary/markdown.md +18 -24
  83. package/docs/ru/intlayer_with_analog.md +8 -14
  84. package/docs/ru/intlayer_with_vite+lit.md +8 -57
  85. package/docs/ru/intlayer_with_vite+vue.md +3 -3
  86. package/docs/tr/dictionary/html.md +11 -8
  87. package/docs/tr/dictionary/markdown.md +18 -24
  88. package/docs/tr/intlayer_with_analog.md +8 -14
  89. package/docs/tr/intlayer_with_vite+lit.md +8 -57
  90. package/docs/tr/intlayer_with_vite+vue.md +3 -3
  91. package/docs/uk/dictionary/html.md +10 -3
  92. package/docs/uk/dictionary/markdown.md +17 -19
  93. package/docs/uk/intlayer_with_analog.md +8 -14
  94. package/docs/uk/intlayer_with_vite+lit.md +8 -57
  95. package/docs/uk/intlayer_with_vite+vue.md +3 -3
  96. package/docs/ur/intlayer_with_vite+lit.md +8 -57
  97. package/docs/vi/dictionary/html.md +10 -3
  98. package/docs/vi/dictionary/markdown.md +17 -19
  99. package/docs/vi/intlayer_with_analog.md +8 -14
  100. package/docs/vi/intlayer_with_vite+lit.md +8 -57
  101. package/docs/vi/intlayer_with_vite+vue.md +3 -3
  102. package/docs/zh/compiler.md +8 -3
  103. package/docs/zh/configuration.md +4 -1
  104. package/docs/zh/dictionary/html.md +11 -8
  105. package/docs/zh/dictionary/markdown.md +18 -24
  106. package/docs/zh/intlayer_with_analog.md +8 -14
  107. package/docs/zh/intlayer_with_vite+lit.md +8 -57
  108. package/docs/zh/intlayer_with_vite+vue.md +3 -3
  109. package/package.json +6 -6
@@ -23,6 +23,14 @@ history:
23
23
 
24
24
  # Übersetzen Sie Ihre Analog (Angular) App mit Intlayer | Internationalisierung (i18n)
25
25
 
26
+ <iframe
27
+ src="https://stackblitz.com/github/aymericzip/intlayer-analog-template?embed=1&ctl=1&file=intlayer.config.ts"
28
+ className="m-auto overflow-hidden rounded-lg border-0 max-md:size-full max-md:h-[700px] md:aspect-16/9 md:w-full"
29
+ title="Demo CodeSandbox - How to Internationalize your application using Intlayer"
30
+ sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
31
+ loading="lazy"
32
+ />
33
+
26
34
  ## Inhaltsverzeichnis
27
35
 
28
36
  <TOC/>
@@ -42,20 +50,6 @@ Mit Intlayer können Sie:
42
50
 
43
51
  ## Schritt-für-Schritt-Anleitung zur Einrichtung von Intlayer in einer Analog-Anwendung
44
52
 
45
- <Tabs defaultTab="code">
46
- <Tab label="Code" value="code">
47
-
48
- <iframe
49
- src="https://stackblitz.com/github/aymericzip/intlayer/tree/main/examples/vite-analog-app?embed=1&ctl=1&file=intlayer.config.ts"
50
- className="m-auto overflow-hidden rounded-lg border-0 max-md:size-full max-md:h-[700px] md:aspect-16/9 md:w-full"
51
- title="Demo CodeSandbox - So internationalisieren Sie Ihre Anwendung mit Intlayer"
52
- sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
53
- loading="lazy"
54
- />
55
-
56
- </Tab>
57
- </Tabs>
58
-
59
53
  Siehe [Anwendungsvorlage](https://github.com/aymericzip/intlayer-analog-template) auf GitHub.
60
54
 
61
55
  ### Schritt 1: Abhängigkeiten installieren
@@ -24,6 +24,14 @@ history:
24
24
 
25
25
  # Übersetzen Sie Ihre Vite- und Lit-Website mit Intlayer | Internationalisierung (i18n)
26
26
 
27
+ <iframe
28
+ src="https://stackblitz.com/github/aymericzip/intlayer-vite-lit-template?embed=1&ctl=1&file=intlayer.config.ts"
29
+ className="m-auto overflow-hidden rounded-lg border-0 max-md:size-full max-md:h-[700px] md:aspect-16/9 md:w-full"
30
+ title="Demo CodeSandbox - How to Internationalize your application using Intlayer"
31
+ sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
32
+ loading="lazy"
33
+ />
34
+
27
35
  ## Inhaltsverzeichnis
28
36
 
29
37
  <TOC/>
@@ -640,63 +648,6 @@ const config: IntlayerConfig = {
640
648
  export default config;
641
649
  ```
642
650
 
643
- <Tabs>
644
- <Tab value='Extract-Befehl'>
645
-
646
- Führen Sie den Extractor aus, um Ihre Komponenten zu transformieren und den Inhalt zu extrahieren
647
-
648
- ```bash packageManager="npm"
649
- npx intlayer extract
650
- ```
651
-
652
- ```bash packageManager="pnpm"
653
- pnpm intlayer extract
654
- ```
655
-
656
- ```bash packageManager="yarn"
657
- yarn intlayer extract
658
- ```
659
-
660
- ```bash packageManager="bun"
661
- bunx intlayer extract
662
- ```
663
-
664
- </Tab>
665
- <Tab value='Babel-Compiler'>
666
-
667
- Aktualisieren Sie Ihre `vite.config.ts`, um das `intlayerCompiler`-Plugin aufzunehmen:
668
-
669
- ```ts fileName="vite.config.ts"
670
- import { defineConfig } from "vite";
671
- import { intlayer, intlayerCompiler } from "vite-intlayer";
672
-
673
- export default defineConfig({
674
- plugins: [
675
- intlayer(),
676
- intlayerCompiler(), // Fügt das Compiler-Plugin hinzu
677
- ],
678
- });
679
- ```
680
-
681
- ```bash packageManager="npm"
682
- npm run build # Oder npm run dev
683
- ```
684
-
685
- ```bash packageManager="pnpm"
686
- pnpm run build # Oder pnpm run dev
687
- ```
688
-
689
- ```bash packageManager="yarn"
690
- yarn build # Oder yarn dev
691
- ```
692
-
693
- ```bash packageManager="bun"
694
- bun run build # Oder bun run dev
695
- ```
696
-
697
- </Tab>
698
- </Tabs>
699
-
700
651
  ### TypeScript konfigurieren
701
652
 
702
653
  Stellen Sie sicher, dass Ihre TypeScript-Konfiguration die automatisch generierten Typen enthält.
@@ -455,14 +455,14 @@ Um die Internationalisierungsfunktionen von Intlayer in Ihrer gesamten Vue-Anwen
455
455
 
456
456
  ```javascript fileName=main.js
457
457
  import { createApp } from "vue";
458
- import { installIntlayer } from "vue-intlayer";
458
+ import { intlayer } from "vue-intlayer";
459
459
  import App from "./App.vue";
460
460
  import "./style.css";
461
461
 
462
462
  const app = createApp(App);
463
463
 
464
464
  // Den Provider auf der obersten Ebene einfügen
465
- installIntlayer(app);
465
+ app.use(intlayer);
466
466
 
467
467
  // Die App mounten
468
468
  app.mount("#app");
@@ -1047,7 +1047,7 @@ import { installIntlayer, installIntlayerMarkdown } from "vue-intlayer";
1047
1047
 
1048
1048
  const app = createApp(App);
1049
1049
 
1050
- installIntlayer(app);
1050
+ app.use(intlayer);
1051
1051
 
1052
1052
  const md = new MarkdownIt({
1053
1053
  html: true, // HTML-Tags erlauben
@@ -296,6 +296,8 @@ The following properties can be configured in the `compiler` block of your `intl
296
296
  - _Type_: `boolean`
297
297
  - _Default_: `false`
298
298
  - _Description_: Indicates if the components should be saved after being transformed.
299
+ - If `true`, the compiler will rewrite the component file in the disk. The transformation will be permanent, and the compiler can then be removed.
300
+ - If `false`, the compiler will inject the `useIntlayer()` function call into the code in the build output only, and keep the base codebase intact. The transformation will be done only in memory.
299
301
 
300
302
  ### Fill missing translation
301
303
 
@@ -936,14 +936,14 @@ Build options apply to the `@intlayer/babel` and `@intlayer/swc` plugins.
936
936
 
937
937
  Settings that control the Intlayer compiler, which extracts dictionaries straight from your components.
938
938
 
939
- | Field | Description | Type | Default | Example | Note |
940
- | --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------- | ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
941
- | `enabled` | Indicates if the compiler should be enabled to extract dictionaries. | `boolean` &#124; <br/> `'build-only'` | `true` | `'build-only'` | `'build-only'` skips the compiler during development to speed up builds; only runs on build commands. |
942
- | `dictionaryKeyPrefix` | Prefix for the extracted dictionary keys. | `string` | `''` | `'my-key-'` | Added to the generated key (based on file name) to prevent conflicts. |
943
- | `saveComponents` | Indicates if components should be saved after being transformed. | `boolean` | `false` | | • If `true`, replaces original files with transformed files.<br/>• The compiler can then be removed after one run. |
944
- | `output` | Defines the output file path. Replaces `outputDir`. Supports template variables: `{{fileName}}`, <br/> `{{key}}`, <br/> `{{locale}}`, <br/> `{{extension}}`, <br/> `{{componentFileName}}`, <br/> `{{componentExtension}}`, <br/> `{{format}}`, <br/> `{{componentFormat}}`, <br/> `{{componentDirPath}}`. | `boolean` &#124; <br/> `FilePathPattern` &#124; <br/> `Partial<Record<Locale, boolean &#124; FilePathPattern>>` | `undefined` | `'./{{fileName}}{{extension}}'` <br/> `'/locales/{{locale}}/{{key}}.json'` <br/> `{ en: ({ key }) => './locales/en/${key}.json', fr: '...', es: false }` | • `./` paths resolve relative to the component directory.<br/>• `/` paths resolve relative to the project root.<br/>• Including `{{locale}}` generates separate per-locale dictionaries.<br/>• Supports per-locale object notation; `false` skips that locale. |
945
- | `noMetadata` | If `true`, the compiler omits dictionary metadata (key, content wrapper) from the output. | `boolean` | `false` | `false` → `{"key":"my-key","content":{"key":"value"}}` <br/> `true` → `{"key":"value"}` | • Useful for i18next or ICU MessageFormat JSON outputs.<br/>• Works well with `loadJSON` plugin. |
946
- | `dictionaryKeyPrefix` | Dictionary key prefix | `string` | `''` | | Add an optional prefix for the extracted dictionary keys |
939
+ | Field | Description | Type | Default | Example | Note |
940
+ | --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------- | ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
941
+ | `enabled` | Indicates if the compiler should be enabled to extract dictionaries. | `boolean` &#124; <br/> `'build-only'` | `true` | `'build-only'` | `'build-only'` skips the compiler during development to speed up builds; only runs on build commands. |
942
+ | `dictionaryKeyPrefix` | Prefix for the extracted dictionary keys. | `string` | `''` | `'my-key-'` | Added to the generated key (based on file name) to prevent conflicts. |
943
+ | `saveComponents` | Indicates if the components should be saved after being transformed. | `boolean` | `false` | | • If `true`, the compiler will rewrite the component file in the disk. The transformation will be permanent, and the compiler can then be removed.<br/>• If `false`, the compiler will inject the `useIntlayer()` function call into the code in the build output only, and keep the base codebase intact. |
944
+ | `output` | Defines the output file path. Replaces `outputDir`. Supports template variables: `{{fileName}}`, <br/> `{{key}}`, <br/> `{{locale}}`, <br/> `{{extension}}`, <br/> `{{componentFileName}}`, <br/> `{{componentExtension}}`, <br/> `{{format}}`, <br/> `{{componentFormat}}`, <br/> `{{componentDirPath}}`. | `boolean` &#124; <br/> `FilePathPattern` &#124; <br/> `Partial<Record<Locale, boolean &#124; FilePathPattern>>` | `undefined` | `'./{{fileName}}{{extension}}'` <br/> `'/locales/{{locale}}/{{key}}.json'` <br/> `{ en: ({ key }) => './locales/en/${key}.json', fr: '...', es: false }` | • `./` paths resolve relative to the component directory.<br/>• `/` paths resolve relative to the project root.<br/>• Including `{{locale}}` generates separate per-locale dictionaries.<br/>• Supports per-locale object notation; `false` skips that locale. |
945
+ | `noMetadata` | If `true`, the compiler omits dictionary metadata (key, content wrapper) from the output. | `boolean` | `false` | `false` → `{"key":"my-key","content":{"key":"value"}}` <br/> `true` → `{"key":"value"}` | • Useful for i18next or ICU MessageFormat JSON outputs.<br/>• Works well with `loadJSON` plugin. |
946
+ | `dictionaryKeyPrefix` | Dictionary key prefix | `string` | `''` | | Add an optional prefix for the extracted dictionary keys |
947
947
 
948
948
  ### Custom Schemas
949
949
 
@@ -19,6 +19,9 @@ slugs:
19
19
  - content
20
20
  - html
21
21
  history:
22
+ - version: 8.5.0
23
+ date: 2026-03-24
24
+ changes: "Add `intlayerHTML` plugin object; use `app.use(intlayerHTML)` instead of `app.use(installIntlayerHTML)`"
22
25
  - version: 8.5.0
23
26
  date: 2026-03-24
24
27
  changes: "move import from `{{framework}}-intlayer` to `{{framework}}-intlayer/html`"
@@ -278,17 +281,17 @@ You can configure HTML rendering globally for your entire application. This is i
278
281
 
279
282
  </Tab>
280
283
  <Tab label="Vue" value="vue">
281
-
284
+
282
285
  ```typescript fileName="main.ts"
283
286
  import { createApp, h } from "vue";
284
- import { installIntlayer } from "vue-intlayer";
285
- import { installIntlayerHTML } from "vue-intlayer/html";
287
+ import { intlayer } from "vue-intlayer";
288
+ import { intlayerHTML } from "vue-intlayer/html";
286
289
  import App from "./App.vue";
287
290
 
288
291
  const app = createApp(App);
289
292
 
290
- app.use(installIntlayer);
291
- app.use(installIntlayerHTML, {
293
+ app.use(intlayer);
294
+ app.use(intlayerHTML, {
292
295
  components: {
293
296
  p: (props, { slots }) => h("p", { class: "prose", ...props }, slots.default?.()),
294
297
  CustomLink: (props, { slots }) => h("a", { href: "/details", ...props }, slots.default?.()),
@@ -302,14 +305,14 @@ You can configure HTML rendering globally for your entire application. This is i
302
305
 
303
306
  ```typescript fileName="main.ts"
304
307
  import { createApp, h } from "vue";
305
- import { installIntlayer } from "vue-intlayer";
306
- import { installIntlayerHTML } from "vue-intlayer/html";
308
+ import { intlayer } from "vue-intlayer";
309
+ import { intlayerHTML } from "vue-intlayer/html";
307
310
  import App from "./App.vue";
308
311
 
309
312
  const app = createApp(App);
310
313
 
311
- app.use(installIntlayer);
312
- app.use(installIntlayerHTML, {
314
+ app.use(intlayer);
315
+ app.use(intlayerHTML, {
313
316
  renderHTML: async (html) => {
314
317
  const { renderHTML } = await import('vue-intlayer/html');
315
318
  return renderHTML(html);
@@ -17,6 +17,9 @@ slugs:
17
17
  - content
18
18
  - markdown
19
19
  history:
20
+ - version: 8.5.0
21
+ date: 2026-03-24
22
+ changes: "Add `intlayerMarkdown` plugin object; use `app.use(intlayerMarkdown)` instead of `app.use(installIntlayerMarkdown)`"
20
23
  - version: 8.5.0
21
24
  date: 2026-03-24
22
25
  changes: "move import from `{{framework}}-intlayer` to `{{framework}}-intlayer/markdown`"
@@ -93,7 +96,7 @@ You can declare Markdown content using the `md` function or simply as a string (
93
96
 
94
97
  ---
95
98
 
96
- ## Part 2: Rendering Markdown
99
+ ## Rendering Markdown
97
100
 
98
101
  Rendering can be handled automatically by Intlayer's content system or manually using specialized tools.
99
102
 
@@ -390,8 +393,6 @@ You can configure Markdown rendering globally for your entire application. This
390
393
 
391
394
  export const AppProvider = ({ children }) => (
392
395
  <MarkdownProvider
393
- forceBlock={true}
394
- tagfilter={true}
395
396
  components={{
396
397
  h1: ({ children }) => <h1 className="text-2xl font-bold">{children}</h1>,
397
398
  a: ({ href, children }) => <Link to={href}>{children}</Link>,
@@ -404,7 +405,7 @@ You can configure Markdown rendering globally for your entire application. This
404
405
 
405
406
  You can also use your own markdown renderer:
406
407
 
407
- ```tsx fileName="AppProvider.tsx"
408
+ ```tsx fileName="AppProvider.tsx"
408
409
  import { MarkdownProvider } from "react-intlayer/markdown";
409
410
 
410
411
  export const AppProvider = ({ children }) => (
@@ -426,21 +427,20 @@ You can configure Markdown rendering globally for your entire application. This
426
427
 
427
428
  ```typescript fileName="main.ts"
428
429
  import { createApp } from "vue";
429
- import { installIntlayer } from "vue-intlayer";
430
- import { installIntlayerMarkdown } from "vue-intlayer/markdown";
430
+ import { intlayer } from "vue-intlayer";
431
+ import { intlayerMarkdown } from "vue-intlayer/markdown";
431
432
  import App from "./App.vue";
432
433
 
433
434
  const app = createApp(App);
434
435
 
435
- app.use(installIntlayer);
436
- app.use(installIntlayerMarkdown, {
437
- forceBlock: true,
438
- tagfilter: true,
436
+ app.use(intlayer);
437
+ app.use(intlayerMarkdown, {
439
438
  components: {
440
- h1: {
441
- component: "h1",
442
- props: { class: "text-2xl font-bold" },
443
- },
439
+ h1: (props) =>
440
+ h('h1', { style: { color: 'orange' }, ...props }, props.children),
441
+ ComponentDemo: () => h('div', { style: { background: 'grey' } }, 'DEMO'),
442
+ bold: (props) => h('strong', props),
443
+ code: (props) => h('code', props),
444
444
  },
445
445
  });
446
446
 
@@ -451,14 +451,14 @@ You can configure Markdown rendering globally for your entire application. This
451
451
 
452
452
  ```typescript fileName="main.ts"
453
453
  import { createApp } from "vue";
454
- import { installIntlayer } from "vue-intlayer";
455
- import { installIntlayerMarkdown } from "vue-intlayer/markdown";
454
+ import { intlayer } from "vue-intlayer";
455
+ import { intlayerMarkdown } from "vue-intlayer/markdown";
456
456
  import App from "./App.vue";
457
457
 
458
458
  const app = createApp(App);
459
459
 
460
- app.use(installIntlayer);
461
- app.use(installIntlayerMarkdown, {
460
+ app.use(intlayer);
461
+ app.use(intlayerMarkdown, {
462
462
  renderMarkdown: async (md) => {
463
463
  const { compileMarkdown } = await import('vue-intlayer/markdown');
464
464
  return compileMarkdown(md);
@@ -480,8 +480,6 @@ You can configure Markdown rendering globally for your entire application. This
480
480
  </script>
481
481
 
482
482
  <MarkdownProvider
483
- forceBlock={true}
484
- tagfilter={true}
485
483
  components={{
486
484
  h1: MyHeading,
487
485
  }}
@@ -517,8 +515,6 @@ You can configure Markdown rendering globally for your entire application. This
517
515
 
518
516
  export const AppProvider = ({ children }) => (
519
517
  <MarkdownProvider
520
- forceBlock={true}
521
- tagfilter={true}
522
518
  components={{
523
519
  h1: ({ children }) => <h1 className="text-2xl font-bold">{children}</h1>,
524
520
  }}
@@ -555,8 +551,6 @@ You can configure Markdown rendering globally for your entire application. This
555
551
 
556
552
  export const AppProvider = (props) => (
557
553
  <MarkdownProvider
558
- forceBlock={true}
559
- tagfilter={true}
560
554
  components={{
561
555
  h1: (props) => <h1 className="text-2xl font-bold">{props.children}</h1>,
562
556
  }}
@@ -23,6 +23,14 @@ history:
23
23
 
24
24
  # Translate your Analog (Angular) app using Intlayer | Internationalization (i18n)
25
25
 
26
+ <iframe
27
+ src="https://stackblitz.com/github/aymericzip/intlayer-analog-template?embed=1&ctl=1&file=intlayer.config.ts"
28
+ className="m-auto overflow-hidden rounded-lg border-0 max-md:size-full max-md:h-[700px] md:aspect-16/9 md:w-full"
29
+ title="Demo CodeSandbox - How to Internationalize your application using Intlayer"
30
+ sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
31
+ loading="lazy"
32
+ />
33
+
26
34
  ## Table of Contents
27
35
 
28
36
  <TOC/>
@@ -42,20 +50,6 @@ With Intlayer, you can:
42
50
 
43
51
  ## Step-by-Step Guide to Set Up Intlayer in an Analog Application
44
52
 
45
- <Tabs defaultTab="code">
46
- <Tab label="Code" value="code">
47
-
48
- <iframe
49
- src="https://stackblitz.com/github/aymericzip/intlayer-analog-template?embed=1&ctl=1&file=intlayer.config.ts"
50
- className="m-auto overflow-hidden rounded-lg border-0 max-md:size-full max-md:h-[700px] md:aspect-16/9 md:w-full"
51
- title="Demo CodeSandbox - How to Internationalize your application using Intlayer"
52
- sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
53
- loading="lazy"
54
- />
55
-
56
- </Tab>
57
- </Tabs>
58
-
59
53
  See [Application Template](https://github.com/aymericzip/intlayer-analog-template) on GitHub.
60
54
 
61
55
  ### Step 1: Install Dependencies
@@ -24,6 +24,14 @@ history:
24
24
 
25
25
  # Translate your Vite and Lit website using Intlayer | Internationalization (i18n)
26
26
 
27
+ <iframe
28
+ src="https://stackblitz.com/github/aymericzip/intlayer-vite-lit-template?embed=1&ctl=1&file=intlayer.config.ts"
29
+ className="m-auto overflow-hidden rounded-lg border-0 max-md:size-full max-md:h-[700px] md:aspect-16/9 md:w-full"
30
+ title="Demo CodeSandbox - How to Internationalize your application using Intlayer"
31
+ sandbox="allow-forms allow-modals allow-popups allow-presentation allow-same-origin allow-scripts"
32
+ loading="lazy"
33
+ />
34
+
27
35
  ## Table of Contents
28
36
 
29
37
  <TOC/>
@@ -41,6 +49,8 @@ With Intlayer, you can:
41
49
 
42
50
  ---
43
51
 
52
+ See [Application Template](https://github.com/aymericzip/intlayer-vite-lit-template) on GitHub.
53
+
44
54
  ## Step-by-Step Guide to Set Up Intlayer in a Vite and Lit Application
45
55
 
46
56
  ### Step 1: Install Dependencies
@@ -643,63 +653,6 @@ const config: IntlayerConfig = {
643
653
  export default config;
644
654
  ```
645
655
 
646
- <Tabs>
647
- <Tab value='Extract command'>
648
-
649
- Run the extractor to transform your components and extract the content
650
-
651
- ```bash packageManager="npm"
652
- npx intlayer extract
653
- ```
654
-
655
- ```bash packageManager="pnpm"
656
- pnpm intlayer extract
657
- ```
658
-
659
- ```bash packageManager="yarn"
660
- yarn intlayer extract
661
- ```
662
-
663
- ```bash packageManager="bun"
664
- bunx intlayer extract
665
- ```
666
-
667
- </Tab>
668
- <Tab value='Babel compiler'>
669
-
670
- Update your `vite.config.ts` to include the `intlayerCompiler` plugin:
671
-
672
- ```ts fileName="vite.config.ts"
673
- import { defineConfig } from "vite";
674
- import { intlayer, intlayerCompiler } from "vite-intlayer";
675
-
676
- export default defineConfig({
677
- plugins: [
678
- intlayer(),
679
- intlayerCompiler(), // Adds the compiler plugin
680
- ],
681
- });
682
- ```
683
-
684
- ```bash packageManager="npm"
685
- npm run build # Or npm run dev
686
- ```
687
-
688
- ```bash packageManager="pnpm"
689
- pnpm run build # Or pnpm run dev
690
- ```
691
-
692
- ```bash packageManager="yarn"
693
- yarn build # Or yarn dev
694
- ```
695
-
696
- ```bash packageManager="bun"
697
- bun run build # Or bun run dev
698
- ```
699
-
700
- </Tab>
701
- </Tabs>
702
-
703
656
  ### Configure TypeScript
704
657
 
705
658
  Ensure your TypeScript configuration includes the autogenerated types.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  createdAt: 2025-04-18
3
- updatedAt: 2025-12-30
3
+ updatedAt: 2026-03-24
4
4
  title: Vite + Vue i18n - How to translate an Vue app in 2026
5
5
  description: Discover how to make your Vite and Vue website multilingual. Follow the documentation to internationalize (i18n) and translate it.
6
6
  keywords:
@@ -17,6 +17,9 @@ slugs:
17
17
  applicationTemplate: https://github.com/aymericzip/intlayer-vite-vue-template
18
18
  youtubeVideo: https://www.youtube.com/watch?v=IE3XWkZ6a5U
19
19
  history:
20
+ - version: 8.5.0
21
+ date: 2026-03-24
22
+ changes: Change installIntlayer by use(intlayer)
20
23
  - version: 7.5.9
21
24
  date: 2025-12-30
22
25
  changes: "Add init command"
@@ -404,19 +407,26 @@ To utilize Intlayer's internationalization features throughout your Vue applicat
404
407
 
405
408
  ```javascript fileName=main.js
406
409
  import { createApp } from "vue";
407
- import { installIntlayer } from "vue-intlayer";
410
+ import { intlayer } from "vue-intlayer";
408
411
  import App from "./App.vue";
409
412
  import "./style.css";
410
413
 
411
414
  const app = createApp(App);
412
415
 
413
416
  // Inject the provider at the top level
414
- installIntlayer(app);
417
+ app.use(intlayer);
415
418
 
416
419
  // Mount the app
417
420
  app.mount("#app");
418
421
  ```
419
422
 
423
+ > You can also call `installIntlayer(app)` directly as a function if you prefer:
424
+ >
425
+ > ```javascript
426
+ > import { intlayer } from "vue-intlayer";
427
+ > app.use(intlayer);
428
+ > ```
429
+
420
430
  Access your content dictionaries throughout your application by creating a main Vue component and using the `useIntlayer` composables:
421
431
 
422
432
  ```vue fileName="src/HelloWord.vue"
@@ -19,6 +19,12 @@ slugs:
19
19
  - content
20
20
  - html
21
21
  history:
22
+ - version: 8.5.0
23
+ date: 2026-03-24
24
+ changes: "Add `intlayerHTML` plugin object; use `app.use(intlayerHTML)` instead of `app.use(installIntlayerHTML)`"
25
+ - version: 8.5.0
26
+ date: 2026-03-24
27
+ changes: "move import from `{{framework}}-intlayer` to `{{framework}}-intlayer/html`"
22
28
  - version: 8.0.0
23
29
  date: 2026-01-22
24
30
  changes: "Add HTMLRenderer / useHTMLRenderer / renderHTML utility"
@@ -260,13 +266,14 @@ You can configure HTML rendering globally for your entire application. This is i
260
266
 
261
267
  ```typescript fileName="main.ts"
262
268
  import { createApp, h } from "vue";
263
- import { installIntlayer, installIntlayerHTML } from "vue-intlayer";
269
+ import { intlayer } from "vue-intlayer";
270
+ import { intlayerHTML } from "vue-intlayer/html";
264
271
  import App from "./App.vue";
265
272
 
266
273
  const app = createApp(App);
267
274
 
268
- app.use(installIntlayer);
269
- app.use(installIntlayerHTML, {
275
+ app.use(intlayer);
276
+ app.use(intlayerHTML, {
270
277
  components: {
271
278
  p: (props, { slots }) => h("p", { class: "prose", ...props }, slots.default?.()),
272
279
  CustomLink: (props, { slots }) => h("a", { href: "/details", ...props }, slots.default?.()),
@@ -17,6 +17,12 @@ slugs:
17
17
  - content
18
18
  - markdown
19
19
  history:
20
+ - version: 8.5.0
21
+ date: 2026-03-24
22
+ changes: "Add `intlayerMarkdown` plugin object; use `app.use(intlayerMarkdown)` instead of `app.use(installIntlayerMarkdown)`"
23
+ - version: 8.5.0
24
+ date: 2026-03-24
25
+ changes: "move import from `{{framework}}-intlayer` to `{{framework}}-intlayer/markdown`"
20
26
  - version: 8.0.0
21
27
  date: 2026-01-22
22
28
  changes: "Add MarkdownRenderer / useMarkdownRenderer / renderMarkdown utility and forceInline option"
@@ -90,7 +96,7 @@ You can declare Markdown content using the `md` function or simply as a string (
90
96
 
91
97
  ---
92
98
 
93
- ## Part 2: Rendering Markdown
99
+ ## Rendering Markdown
94
100
 
95
101
  Rendering can be handled automatically by Intlayer's content system or manually using specialised tools.
96
102
 
@@ -387,8 +393,6 @@ You can configure Markdown rendering globally for your entire application. This
387
393
 
388
394
  export const AppProvider = ({ children }) => (
389
395
  <MarkdownProvider
390
- forceBlock={true}
391
- tagfilter={true}
392
396
  components={{
393
397
  h1: ({ children }) => <h1 className="text-2xl font-bold">{children}</h1>,
394
398
  a: ({ href, children }) => <Link to={href}>{children}</Link>,
@@ -404,20 +408,20 @@ You can configure Markdown rendering globally for your entire application. This
404
408
 
405
409
  ```typescript fileName="main.ts"
406
410
  import { createApp } from "vue";
407
- import { installIntlayer, installIntlayerMarkdown } from "vue-intlayer";
411
+ import { intlayer } from "vue-intlayer";
412
+ import { intlayerMarkdown } from "vue-intlayer/markdown";
408
413
  import App from "./App.vue";
409
414
 
410
415
  const app = createApp(App);
411
416
 
412
- app.use(installIntlayer);
413
- app.use(installIntlayerMarkdown, {
414
- forceBlock: true,
415
- tagfilter: true,
417
+ app.use(intlayer);
418
+ app.use(intlayerMarkdown, {
416
419
  components: {
417
- h1: {
418
- component: "h1",
419
- props: { class: "text-2xl font-bold" },
420
- },
420
+ h1: (props) =>
421
+ h('h1', { style: { color: 'orange' }, ...props }, props.children),
422
+ ComponentDemo: () => h('div', { style: { background: 'grey' } }, 'DEMO'),
423
+ bold: (props) => h('strong', props),
424
+ code: (props) => h('code', props),
421
425
  },
422
426
  });
423
427
 
@@ -434,8 +438,6 @@ You can configure Markdown rendering globally for your entire application. This
434
438
  </script>
435
439
 
436
440
  <MarkdownProvider
437
- forceBlock={true}
438
- tagfilter={true}
439
441
  components={{
440
442
  h1: MyHeading,
441
443
  }}
@@ -452,8 +454,6 @@ You can configure Markdown rendering globally for your entire application. This
452
454
 
453
455
  export const AppProvider = ({ children }) => (
454
456
  <MarkdownProvider
455
- forceBlock={true}
456
- tagfilter={true}
457
457
  components={{
458
458
  h1: ({ children }) => <h1 className="text-2xl font-bold">{children}</h1>,
459
459
  }}
@@ -471,8 +471,6 @@ You can configure Markdown rendering globally for your entire application. This
471
471
 
472
472
  export const AppProvider = (props) => (
473
473
  <MarkdownProvider
474
- forceBlock={true}
475
- tagfilter={true}
476
474
  components={{
477
475
  h1: (props) => <h1 className="text-2xl font-bold">{props.children}</h1>,
478
476
  }}