How it works...

The Lightning JavaScript Controller is a client-side controller that handles events and defines the functions associated with the Lightning Component. In the context of the framework for our "Search First Before You Create" Lightning Component, it is described by Salesforce as follows:

A client-side controller handles events within a component. It's a JavaScript resource that defines the functions for all of the component's actions.

A client-side controller is a JavaScript object in object-literal notation containing a map of name-value pairs. Each name corresponds to a client-side action. Its value is the function code associated with the action. Client-side controllers are surrounded by parentheses and curly braces. Separate action handlers with commas (as you would with any JavaScript map).
Reference:

 
Lightning Components Developer Guide: Handling Events with Client-Side Controllers

 https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/js_client_side_controller.htm
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset