Migrating Visualforce pages to Salesforce Lightning

Migrating visualforce pages to Salesforce Lightning
You know those complicated screens in your org? You are going to have to tackle them.

Our Advanced Salesforce Developer Simon Lawrence tells us how to migrate complex visualforce pages to Salesforce Lightning.

Do you have a screen in your business that looks a bit like this?

 

Visualforce page in Salesforce Classic

 

Itโ€™s not great, and why would it be – it has not been updated for about 9 years. Thatโ€™s because nobody dares touch it. There are two reasons for this.

  1. It works but no one really knows exactly how it works
  2. It is business critical – the entire operation of your business could actually crash and burn if you took this one page away.

You might be surprised by just how often we come across one of these pages.

But now you have a problem because itโ€™s this page that is stopping you from migrating to Lightning. You may well have given it a go e.g. you flipped the switch and took a look at what happened. In actual fact, at first glance, it did not appear to be too far wrong.

 

Visualforce page in Classic converted to Lightn

 

OK there is a space where the side bar used to be in Classic. The fonts have gone a bit haywire. Itโ€™s nothing that you canโ€™t convince your team to get used to.

The problem occurs when you attempt to update the screen. Thatโ€™s when you get one of these messages.

 

Visualforce page in Classic converted to Lightn

And nothing works. And with that, things just got complicated.

Lightning is incredibly tolerant in what can be brought forward from Classic. Therefore, if a feature of your org doesnโ€™t come across smoothly, itโ€™s probably for a very good reason; perhaps security model breaches, scalability issues – we commonly see major Cross-Site Request Forgery (CSRF) or Cross-origin resource sharing (CORS) issues on pages like this.

The time has come. You have to tackle this screen.

But let me reassure you, it will be OK.

It will be OK because you now have Lightning Components. Salesforce has now given us the tools and the knowledge to rebuild functionality in Lightning Web Components much, much faster than we were ever able to in Visualforce and Apex. Along the way, we now have the opportunity to make sweeping improvements to business processes, scalability and maintainability.

Goodbye complex, old skool โ€˜single page applicationsโ€™, hello, dynamic, componentised Lightning web applications.

Still wondering how to make the first move? I would suggest you prepare by taking a look at the some of the information available on Lightning App Builder, IDE Plugins and Salesforce DX – Iโ€™ve included some useful links.

Good luck. Drop me a comment below if it gets really complicated and Iโ€™ll see if I can help.

Work with Desynit

Looking for exceptional, professional Salesforce support?

Our independent tech team has been servicing enterprise clients for over 15 years from our HQ in Bristol, UK. Let’s see how we can work together and get the most out of your Salesforce implementation.