A Lightning component bundle includes following resources:
Resource | Resource Name | Usage |
---|---|---|
Component or Application | sample.cmp or sample.app |
The only required resource in a bundle. Contains markup for the component or app. Each bundle contains only one component or app resource. |
Controller | sampleController.js |
Contains client-side controller methods to handle events in the component. |
Helper | sampleHelper.js |
JavaScript functions that can be called from any JavaScript code in a component’s bundle |
CSS Styles | sample.css |
Contains styles for the component. |
Documentation | sample.auradoc |
A description, sample code, and one or multiple references to example components |
Renderer | sampleRenderer.js |
Client-side renderer to override default rendering for a component. |
Design | sample.design |
File required for components used in Lightning App Builder, Lightning pages, Community Builder, or Cloud Flow Designer. |
SVG File | sample.svg |
Custom icon resource for components used in the Lightning App Builder or Community Builder. |