Reusable components allow you to create and update a component in a central location, the Global Node, and then share it on multiple different web pages on your website. They can help you save time when creating content and make it easier to update content site-wide so you don't need to change content on multiple pages.
You can include multiple content components in a reusable component.
Create and edit a reusable component
To create a reusable component which you can then use on a web page:
- Navigate to the Global Node in the left navigation tree in the Content section of the Govstack back office
- Select 'Reusable Components' from the menu options
- Select 'Create Component Group'
- In the 'Enter a name...' field, create a name for your reusable component
- Select 'Add content' to add the components you want to include
You can now edit each content component as you would on a regular web page.
Add a reusable component to a page
To add a reusable component to a content page, you need to:
- Navigate to the page that you want to add the reusable component to
- Under the 'Content' tab at the top, scroll down to 'Main content' and select 'Add content'
- Select 'Reusable Components' from the list of components
- Select 'Add'
- Choose from your list of reusable components or use the search bar to find the reusable component you want to add
- Then, select 'Submit'
- Select 'Create' to add the reusable component to your page
Now, any time you update the reusable component in the Global Node, it will automatically update on each page that you've added the reusable component to.