Book Image

Learning Salesforce Lightning Application Development

By : Mohit Shrivatsava
Book Image

Learning Salesforce Lightning Application Development

By: Mohit Shrivatsava

Overview of this book

Built on the Salesforce App Cloud, the new Salesforce Lightning Experience combines three major components: Lightning Design System, Lightning App Builder, and Lightning Components, to provide an enhanced user experience. This book will enable you to quickly create modern, enterprise apps with Lightning Component Framework. You will start by building simple Lightning Components and understanding the Lightning Components architecture. The chapters cover the basics of Lightning Component Framework semantics and syntax, the security features provided by Locker Service, and use of third-party libraries inside Lightning Components. The later chapters focus on debugging, performance tuning, testing using Lightning Testing Services, and how to publish Lightning Components on Salesforce AppExchange.
Table of Contents (22 chapters)
Title Page
PacktPub.com
Foreword
Contributors
Preface
Index

Chapter 4. The Lightning JavaScript API

In this chapter, we will dig deeper into the Lightning component rendering life cycle and its JavaScript API. The Lightning Component framework typically uses the ES5 version of JavaScript. However, some ES6 support is built in, including the use of Promises and, array functions. The Lightning component framework does not support all of the APIs in JavaScript ES5 specifications, due to security. Only APIs that are considered safe from a web security perspective are supported by the framework. Salesforce runs the custom JavaScript that we write in the helper, controller, or RENDERER files, through a service known as a locker service, which ensures that your JavaScript code is safe and compliant with security.

This chapter will start with the various system-specific JavaScript functions and APIs provided by the Lightning framework, and we will then dig deeper into its rendering cycle, followed by a section on Locker Services.

In this chapter, we will cover...