You need to sign in to do that
Don't have an account?
Rujuta Honrao
What are the advantages of using Design Tokens ? Should I prefer Design Tokens or Static Resources ?
I was reading https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/tokens_intro.htm (https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/tokens_intro.htm" target="_blank) . But, I found this similar to using static resources, like the same type of styling can also be done using staic resources and the CSS also looks the same like in Salesforce Classic, so what is the difference ? Why should I use Design Tokens ? What are the advantages of Design Tokens ? Can someone please help me over this ?
- With the design token you can create a baseDesign token and you can define the common css at one place and it will be inherited to all the component by default .. So all CSS will be centralized
- You will be getting an option to override
Refer this linkhttps://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/tokens_using.htm
With the Static Resource, you can able to upload css and import them into the lib .. with this approach all css will be in resource and eevry time you need to refer them
No override
static resources Advantages
Design Tokens