function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
FSamorganFSamorgan 

[Salesforce] Customers should be namespacing their JavaScript code

This is a warning to every Visualforce developer here. Salesforce will clober your javascript at any time with no warning. I experienced a 100% customer outage due to Salesforce updating their Javascript in the middle of the night a couple weeks ago. This was their customer support response from tier 3:


"Customers should be namespacing (well, pseudo-namespacing) their JavaScript code to avoid collisions like this. That's just standard web development method."

"Salesforce libraries are growing faster and we cannot possibly document every global variable/function that we're adding to the JavaScript that is served with Salesforce."
 
J. Scott CromieJ. Scott Cromie
Wish I could "unlike" this.