fb-share
Contact Us menu-bars menu-close

Getting Smart with Winter’18 Release

avatar

Ameya Wadke

January 03, 2018

At a time when everyone is eager to onboard the Lightning experience, converting the Visualforce pages to lightning was a huge task. Although there were workarounds, like identifying the UI and rendering the section accordingly, it was not the most optimal solution, as code would have to be repeated. This would then need to be followed up by adding the SLDS class for styling the tags in order to help them match the lightning experience. Quite a task!

To overcome this, Salesforce has given us an early Christmas gift! With the Winter’18 release, Salesforce introduced a new attribute as lightningStylesheets. Using this within the apex:page, the need to identify and re-write the code with all SLDS classes is eliminated altogether. Salesforce internally changes the Visualforce page to a lightning experience. Yes, you read that right! All the tags match the corresponding lightning:input tag and are displayed as per the type.

This new attribute is of Boolean type and if set as true, automatically on switch, changes the UI of page as per the salesforce UI.

Limitations

A known issue with the functioning of this attribute is on the lines of the showHeader attribute. Even though the page has specified showHeader as true, whenever user switches to the lightning experience, the showHeader attribute is overwritten to false.

Limitation apart, this attribute saves a lot of time that was otherwise being spent on manual changes. Couldn’t ask for a better gift from Salesforce now, could I?

Get updates. Sign up for our newsletter.

contact-bg

Let's explore how we can create WOW for you!