WordPress / Documentation-Issue-Tracker

Issue Tracker for the WordPress Documentation team.
https://make.wordpress.org/docs/
Other
83 stars 41 forks source link

Theme developer handbook: Add theme.json information to the child theme page #662

Open carolinan opened 1 year ago

carolinan commented 1 year ago

Issue Description

Add information about using theme.json in child themes to the child themes page.

URL of the Page with the Issue

https://developer.wordpress.org/themes/advanced-topics/child-themes/

Section of Page with the issue

Why is this a problem?

People are unsure of if they can use theme.json in child themes, and if and how they can use a child theme to override the parent theme theme.json.

Suggested Fix

Add the missing information.

zzap commented 1 year ago

Heads up @WordPress/docs-issues-coordinators, we have a new issue open. Time to use 'em labels.

github-actions[bot] commented 1 year ago

Heads up @kafleg @carolinan @TeBenachi - the "themes" label was applied to this issue.

carolinan commented 1 year ago

After consideration, I added it to the theme.json handbook page, under the existing heading "A theme.json can be added to any theme". Scheduled update. I have scheduled the update for Sat, February 17, 2029 12:28 pm so there is plenty of time to review it 😸

Theme.json in child themes

Theme.json can be added to any type of child theme, regardless of if the parent theme is a block theme or a classic theme. You can add theme.json to a child theme to override the settings and styles in the parent theme's theme.json. Any feature that is in the parent theme's theme.json, but not in the child theme, is inherited. This means that you can replace all or some of the parent theme settings.