this.theme

October CMS Documentation Docs

this.theme

Используйте переменную this.theme, чтобы получить информацию о текущей теме. You can access the current theme object via this.theme and it returns the object Cms\Classes\Theme, a reference to the theme customization object.

# Свойства

Объект this.theme класса Cms\Classes\Theme имеет прямой доступ к полям темы, а также имеет следующие свойства.

# id

Преобразует имя папки с темой в CSS-идентификатор.

<body class="theme-{{ this.theme.id }}">

# config

Массив, с настройкам темы, которые были найденные в файле theme.yaml.

<meta name="description" content="{{ this.theme.config.description }}">
На этой странице