Skip to main content
Level 2
Nov 2, 2023 6:38 AM UTC
Solved

Extending component style policies

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.
Mahedi_Sabuj
Mahedi_SabujAccepted solution
Community Advisor
Nov 6, 2023 1:26 PM UTC

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

2 replies

Mahedi_Sabuj
Community Advisor
Mahedi_SabujCommunity AdvisorAccepted solution
Community Advisor
Nov 6, 2023 1:26 PM UTC

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.

Translate
Mahedi Sabuj
kautuk_sahni
Level 9
Nov 9, 2023 12:05 PM UTC

@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.

Translate
Kautuk Sahni