19

The requirement was to open a Lightning App page and pass some query parameters in the URL. These query parameters were then used to query data and display in a Lightning component present in the Lightning App.

Till Spring 19, it was working fine. This was the URL format:

force.com/lightning/n/Document_Upload?id=0015B00000fS9mzQAC&type=AccountDocument

where Document_Upload was the name of the Lightning App and 'id' and 'type' were the query parameters.

In Summer 19, the same URL format doesn't work.

In fact, any query parameter appended to a page is removed as the page loads.

So, this URL,

force.com/lightning/n/Document_Upload?id=0015B00000fS9mzQAC&type=AccountDocument

becomes

force.com/lightning/n/Document_Upload

How do I pass query parameters here?

2 Answers 2

33

I think there is a Critical Update that gets auto-enabled for Summer '19, that forces Lightning URL parameters to be namespaced. And the default namespace for orgs is "c".

So if you add ?foo=bar to the URL, it will get auto-stripped.

But if you add ?c__foo=bar to the URL, it will persist.

3
2

Here is the Salesforce critical update that talks about this.

1
  • 2
    Please put the relevant part of this information here, in your answer.
    – isherwood
    Commented Oct 21, 2020 at 12:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .