Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Path to Code
Begin Your Salesforce Coding Adventure
Episode 15
Basics of JavaScript
Jitendra Zaa
Salesforce MVP
Sr Technical Architect
23x Certified
@Jitendra Zaa
Speaker
Some House Rules
• Please mute your mic
• Keep adding questions in Zoom Q&A Window
• No question is too small
• Questions ...
Agenda
• Introduction to JavaScript
• Hoisting
• var vs let vs const
• Different ways to write functions
• Arrow Functions...
History of JavaScript
1995
• Mocha created by Brendan Eich in 10 days
• Renamed to LiveScript Officially
• To piggyback popularity of Java, rena...
1996
• Worried about future and standardization , Ecma group was
introduced to decide feature and capabilities of language...
Basics of JavaScript
Hoisting
Hoisting
The process of assigning variable declarations a default value of
undefined during the creation phase is called H...
Demo 1
Hoisting
Var
Var :
function scoped
undefined when accessing a variable before it’s declared
let
let :
block scoped
ReferenceError when accessing a variable before it’s declared
const
const :
block scoped
ReferenceError when accessing a variable before it’s declared
Can’t be reassigned
Demo 2
Different ways to write functions
Demo 3
Sequence of Method matters ?
Demo 4
Recursion
Demo 5
Arguments.Callee
Arrow Functions
Arrow Function
var multiplyES5 = function(x, y) {
return x * y;
};
const multiplyES6 = (x, y) =>
{ return x * y };
Memoization
Memoization is programming practice in which returned results from
functions are saved in cache, thus boosting...
Demo 6
Memoization and Arrow Methods
Promises
Are Asynchronous
Has three states
1. Pending
2. Fulfilled
3. Rejected
Reference
• Secrets of Javascript by John Resig
• Hoisting
• Arrow Functions
Q&A
Next Episode 16
Getting Started with Lightning Web Components
Thanks
Episode 15 - Basics of Javascript
You’ve finished this document.
Download and read it offline.
Upcoming SlideShare
What to Upload to SlideShare
Next
Upcoming SlideShare
What to Upload to SlideShare
Next
Download to read offline and view in fullscreen.

2

Share

Episode 15 - Basics of Javascript

Download to read offline

Basics of Javascripts for Salesforce Developers

Related Audiobooks

Free with a 30 day trial from Scribd

See all

Episode 15 - Basics of Javascript

  1. 1. Path to Code Begin Your Salesforce Coding Adventure
  2. 2. Episode 15 Basics of JavaScript
  3. 3. Jitendra Zaa Salesforce MVP Sr Technical Architect 23x Certified @Jitendra Zaa Speaker
  4. 4. Some House Rules • Please mute your mic • Keep adding questions in Zoom Q&A Window • No question is too small • Questions will be answered in last 15 mins
  5. 5. Agenda • Introduction to JavaScript • Hoisting • var vs let vs const • Different ways to write functions • Arrow Functions • Recursion • Arguments.Callee • Memoization • Promises
  6. 6. History of JavaScript
  7. 7. 1995 • Mocha created by Brendan Eich in 10 days • Renamed to LiveScript Officially • To piggyback popularity of Java, renamed to JavaScript • Worried about Java Trademark, Microsoft released its own version of JavaScript as JScript
  8. 8. 1996 • Worried about future and standardization , Ecma group was introduced to decide feature and capabilities of language • EcmaScript was trademarked by Ecma group to define the standard of JavaScript
  9. 9. Basics of JavaScript
  10. 10. Hoisting
  11. 11. Hoisting The process of assigning variable declarations a default value of undefined during the creation phase is called Hoisting.
  12. 12. Demo 1 Hoisting
  13. 13. Var Var : function scoped undefined when accessing a variable before it’s declared
  14. 14. let let : block scoped ReferenceError when accessing a variable before it’s declared
  15. 15. const const : block scoped ReferenceError when accessing a variable before it’s declared Can’t be reassigned
  16. 16. Demo 2 Different ways to write functions
  17. 17. Demo 3 Sequence of Method matters ?
  18. 18. Demo 4 Recursion
  19. 19. Demo 5 Arguments.Callee
  20. 20. Arrow Functions
  21. 21. Arrow Function var multiplyES5 = function(x, y) { return x * y; }; const multiplyES6 = (x, y) => { return x * y };
  22. 22. Memoization Memoization is programming practice in which returned results from functions are saved in cache, thus boosting the performance of long running / iterative methods.
  23. 23. Demo 6 Memoization and Arrow Methods
  24. 24. Promises Are Asynchronous Has three states 1. Pending 2. Fulfilled 3. Rejected
  25. 25. Reference • Secrets of Javascript by John Resig • Hoisting • Arrow Functions
  26. 26. Q&A
  27. 27. Next Episode 16 Getting Started with Lightning Web Components
  28. 28. Thanks
  • SivaMiriyala

    Jun. 1, 2020
  • ElhadjimoryNdaw

    Nov. 5, 2019

Basics of Javascripts for Salesforce Developers

Views

Total views

9,983

On Slideshare

0

From embeds

0

Number of embeds

9,689

Actions

Downloads

17

Shares

0

Comments

0

Likes

2

×