Skip to content

Removing Themes from the Feature Pack

If you decide to stop using Themes after including it in your feature pack, you must delete the blocks.json file from your project or repository. However, after removing the blocks.json file, you must apply additional configurations to preserve all of the PageBuilder Engine capabilities.

This guide walks you through configuring your project without Themes.

Site properties

When using Themes, you define your site properties in the blocks.json file. Without the blocks.json file, you must set your site properties inside the /properties directory of your project. See How to use site properties for the correct placement of site properties.

Site-specific CSS

Themes enables site-specific CSS overrides for some chosen fields and includes variables and functions to achieve a consistent design. When removing Themes, you lose the site-specific CSS overrides feature and must include CSS files separately for each site.

PageBuilder Engine supports site-specific CSS. For information on configuring and keeping the CSS files as small as possible for each site, see PageBuilder Engine Multi-site styling support.

Component CSS

Any CSS included on the component level can stay as is and requires no change. See How to add styling to components for complete information on using static tags and importing styles into components.

fusion:themes package

You must remove all references to the fusion:themes package from your code.

OutputType

If you previously used the Themes outputType, your custom outputType must import the generated CSS in the head tag by adding <props.cssLinks />. See Output Type API for more details.

Engine SDK

The Engine SDK package provides components to use with Themes and custom code. Depending on your use case, you can use the Engine SDK individually, but you might require specific data structures (page-type metadata), variables, or content sources. You can add the package to your package.json file, which requires a GitHub personal access token with read permissions in the .npmrc file. See Configuring environment variables to add the .npmrc file to your project.

Internationalization

You do not have to make any changes if you use internationalization in Themes. However, you must include the desired languages in the blocks.json file, which is not required if you are providing all translations yourself.

Ensure that you have locale in your copied site properties, and remove all Themes override entries from your intl.json file. For more information, see Internationalization.