Extending component style policies | Community
Skip to main content
Level 2
November 2, 2023
Solved

Extending component style policies

  • November 2, 2023
  • 2 replies
  • 1018 views

Hi Team,

I extended component A to component B, so, I have style policies for component A how to get that style policies in component B.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Mahedi_Sabuj

To extend component A to component B and inherit the style policies of component A, you can proceed as follows:

1. In component B, ensure that you've configured the sling:resourceSuperType property to reference the resource type of component A.

2. By extending component B from component A using the sling:resourceSuperType, component B will automatically inherit the style policies defined for component A.

3. You can confirm this inheritance by checking the Component Policy section in the Edit Template.

2 replies

Mahedi_Sabuj
Community Advisor
Mahedi_SabujCommunity AdvisorAccepted solution
Community Advisor
November 6, 2023

To extend component A to component B and inherit the style policies of component A, you can proceed as follows:

1. In component B, ensure that you've configured the sling:resourceSuperType property to reference the resource type of component A.

2. By extending component B from component A using the sling:resourceSuperType, component B will automatically inherit the style policies defined for component A.

3. You can confirm this inheritance by checking the Component Policy section in the Edit Template.

Mahedi Sabuj
kautuk_sahni
Community Manager
Community Manager
November 9, 2023

@kkeerthi Did you find the suggestions from users helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community.

Kautuk Sahni