What is a global function | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 7

What is a global function

25th Jun 2018, 2:31 PM
Daniel O'Brien
Daniel O'Brien - avatar
7 Answers
+ 7
A global function can be accessed from anywhere in the program.
25th Jun 2018, 11:42 PM
Scott
+ 5
Lisa F js has inheritance since es6
16th Jul 2018, 12:35 PM
Haris
Haris - avatar
+ 4
an example of a global function: window.onload = function() { statements };
26th Jun 2018, 5:15 AM
Haris
Haris - avatar
+ 3
Haris ok "no inheritance like java" javascript has prototypal inheritance which is different. imo in javascript it is best to learn the basics of the language first. for javascript that means learn prototypes first. !!
16th Jul 2018, 12:44 PM
Lisa F
Lisa F - avatar
+ 1
javascript doesn't have the main object. that's java. inheritance is not like java inheritance.
16th Jul 2018, 12:19 PM
Lisa F
Lisa F - avatar
0
how to create html website
26th Jun 2018, 6:40 AM
Omoh Job
0
local functions exist too?
26th Jun 2018, 11:54 AM
Jesse Lux
Jesse Lux - avatar