Theme YAML – Use YAML instead JSON for your theme.json settings and styles

Theme YAML – Use YAML instead JSON for your theme.json settings and styles Install Statistics

0
100%
Today: 0 Yesterday: 0 All-time: 705 downloads
Theme YAML – Use YAML instead JSON for your theme.json settings and styles Icon

Try plugin: Theme YAML – Use YAML instead JSON for your theme.json settings and styles

We'll create fresh WordPress site with Theme YAML – Use YAML instead JSON for your theme.json settings and styles installed. You have 20 minutes to test the plugin after that site we'll be deleted.

Takes ~10 seconds to install.

About Theme YAML – Use YAML instead JSON for your theme.json settings and styles

Theme Yaml converts your theme.yaml file into theme.json so that you can configure your theme with YAML

1


1


0


0


0

updated: 1 year ago
since: 2 years ago
author: Sascha Paukner

Description

Theme Yaml converts your theme.yaml file into theme.json so that you can configure your theme with YAML. It has the benefit of being able to add comments and is more concise than JSON. The generated theme.json is left as a one liner by default, so that you can see it is generated. This however can be changed through the ‘theme_yaml_json_pretty_print’ filter.

The plugin automatically looks for a theme.yaml file in the active theme’s root folder when a page is loaded. If found, it will check its last modified time and store the value in the database. If there are new modifications, the plugin parses theme.yaml, converts it to JSON, and writes it to the theme.json file.

If the active theme is a child, it will also automatically run through this process for its parent.

Configuration

Add a theme.yaml file with your theme settings in your theme’s root directory. If you already have an existing theme.json file, you can convert it to the YAML format using an online tool. I personally use https://www.json2yaml.com/. The plugin will then convert the theme.yaml file into JSON and save it to the theme.json file.