How to Use Wrapper Class In Salesforce Lightning Component?
A wrapper or container class is a class, a data structure, or an abstract data type which contains different objects or collection of objects as its members.
A snippet of code for Wrapper Class :
To use a variable in lightning use @AuraEnabled Annotation before the variable name. Above wrapper class can be use to show account Details and all its related contact.
A snippet of code for Lightning Component :
Helper For Lightning Component :
Salesforce Apex Controller :
The above lightning component is embedded in a visual force page.
A snippet of code for Salesforce Visualforce Page :
Your Lightning Component Look like Below ScreenShot :