Add Salesforce Lightning Design System in Visualforce Page

I know it’s a pretty old thread, but still would like to add:

  1. You don’t need to add lightning css as static resource. Just include this tag on top of your VF page: <apex:slds />.
  2. Pass the icon reference directly as shown below:/apexpages/slds/latest/assets/icons/standard-sprite/svg/symbols.svg#opportunity

Example:

<use xmlns:xlink="http://www.w3.org/1999/xlink" 
    xlink:href="/apexpages/slds/latest/assets/icons/standard-sprite/svg/symbols.svg#opportunity">
</use>

Published by Ayub Ansar!

Salesforce Developer, Admin, Customer, Partner....everything...simply love Salesforce and love to help people ...

One thought on “Add Salesforce Lightning Design System in Visualforce Page

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: