Salesforce Certified Platform Developer II — Question 154

How can a developer efficiently incorporate multiple JavaScript libraries, such as JQuery and MomentJS, in a Lightning component?

Answer options

Correct answer: D

Explanation

The correct answer is D because combining multiple assets into a single static resource optimizes loading times and simplifies management. Options A and B are less efficient as they involve external calls or multiple script tags, while option C does not leverage the advantages of using static resources for bundling libraries.