Пользовательское выравнивание

Меньше 1 минутыMarkdownВыравниваниеMarkdown

Внедрив конфигурацию в vuepress-plugin-container, вы можете использовать

::: center
Абзац в центре
:::

::: right
Абзац справа
:::

Чтобы настроить выравнивание абзаца.

Конфиг

// .vuepress/config.ts
import { defineUserConfig } from "vuepress";
import { hopeTheme } from "vuepress-theme-hope";

export default defineUserConfig({
  theme: hopeTheme({
    plugins: {
      mdEnhance: {
        align: true,
      },
    },
  }),
});







 
 
 



Демо

Предупреждение

vuepress-theme-hope v2 is still in W.I.P, the API may have

Significant changes.

If you meet a bug during usage, you can

:::: danger
vuepress-theme-hope v2 is still in W.I.P, the API may have

::: center
Significant changes.
:::

If you meet a bug during usage, you can

::: right
[open an issue](https://github.com/vuepress-theme-hope/vuepress-theme-hope/issues).
:::
::::