- They are the self-contained and reusable units of an App. Apps can be either a single component or group of multiple components.
- Components are standalone and can be resolved in client side (i.e. browser) without making iterative server calls.
- Component bundle consists of 8 resources. The most important ones are
- Component:
- This is where you can build your UI using Aura tags.
- Controller:
- Just like Apex controller used in VF pages, we have controller for Lightning Components.
- These controller can perform all the logical task in the client side without any server calls.
- It is done using Javascript.
- They also acts as an bridge and can call the server Apex methods.
- Helper:
- The reusable code of your component can be built here.
- It is a best practice to write the code in helper so that the component is lightweight and the application flow is easy to understand.
- Style:
- Any custom CSS can be stored here.
- Before building any custom CSS, have you seen the Salesforce Lightning Design System (SLDS). It allows you to build jaw dropping UI without any CSS!
Learn Salesforce Lightning with me. I am creating this blog to post the solutions which I have come up with during my lightning development experience. I would like to keep it simple and give you references to read further.
Saturday, April 16, 2016
Lightning Component/Component bundle
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment