mdn/js/0_javascript_first_steps/0_what_is_javascript

0_what_is_javascript

dz / mdn / js / 0_javascript_first_steps / 0_what_is_javascript

Summary

What is Javascript?

Node Tree

Nodes

javascript
content JavaScript
children API, QuerySelectorAll, addEventListener, builds_on_html_css, client_side, comments, dynamic, event_listener, exec_environment, implement_complex_features_on_web, inline_js_handlers, interpretted, multiline, tag_script, uses_script_tag

implement_complex_features_on_web
content Scripting/programming language that allows you to implement complex features on web pages
children complex_feature_ex (examples of "complex features")
parents javascript

complex_feature_ex
content Create dynamically udpating content, control multimedia, animate images
parents implement_complex_features_on_web

builds_on_html_css
content Buils on top of HTML, CSS
parents javascript

API
content Application Programming Interface (API)
children browser_API, ready_made_set_code_building_blocks (description), third_party_API
parents javascript

ready_made_set_code_building_blocks
content ready-made set of code building blocks that allow a dev to implement programs otherwise hard or impossible
parents API

browser_API
content Browser APIs
children AV_APIs, DOM_API, canvas_webgl, geolocation
parents API

DOM_API
content DOM API
parents browser_API

geolocation
content Geolocation
parents browser_API

canvas_webgl
content Canvas / WebGL
parents browser_API

AV_APIs
content AV APIs HTMLMediaElement and WebRTC
parents browser_API

third_party_API
content Third-Party APIs
children google_maps, grab_code_info_somewhere, twitter
parents API

twitter
content twitter
parents third_party_API

google_maps
content Google Maps
parents third_party_API

grab_code_info_somewhere
content Generally have to grab code and info somewhere on the web.
parents third_party_API

exec_environment
content Execution environment
children bucket_for_running_code, code_run_separately
parents javascript

bucket_for_running_code
content Each browser tab has its own bucket for running code in
parents exec_environment

code_run_separately
content Code is run separately
parents exec_environment

interpretted
content Interpretted
children compiled (versus), just_in_time_compiling
parents javascript

compiled
content Compiled
parents interpretted

just_in_time_compiling
content Most modern JS interpreters use a technique called just-in-time compiling to improve performance
parents interpretted

client_side
content Client-side
children run_on_users_computer, server_side (versus)
parents javascript

server_side
content Server-sisde
children server_side_languages
parents client_side

run_on_users_computer
content Run on Users Computer
parents client_side

server_side_languages
content PHP, Python, Ruby, ASP.NET, Javascript (via node.js)
parents server_side

dynamic
content Dynamic
children ability_to_update_page (description), static_code (versus)
parents javascript

static_code
content Static code
parents dynamic

ability_to_update_page
content Ability to udpate display of web page / app to show different things in different circumstances
parents dynamic

uses_script_tag
content Uses <script>
children external, internal
parents tag_script, javascript

internal
content internal
children external (versus)
parents uses_script_tag

external
content external
parents internal, uses_script_tag

inline_js_handlers
content Inline JS handlers
parents javascript
remarks bad practice to use these

QuerySelectorAll
content QuerySelectorAll()
parents addEventListener, javascript

addEventListener
content addEventListener()
children DOMContentLoaded, QuerySelectorAll
parents event_listener, javascript

event_listener
content Event Listener
children addEventListener
parents javascript

DOMContentLoaded
content DOMContentLoaded
children HTML_body_parsed
parents addEventListener

tag_script
content <script>
children defer, uses_script_tag
parents javascript

defer
content defer
children HTML_body_parsed (modern approach), async
parents tag_script

HTML_body_parsed
content Signifies HTML body is parsed
parents defer, DOMContentLoaded

async
content async vs
children download_noblock, load_background_ASAP (when to use)
parents defer

load_background_ASAP
content Should be used to load in place background scripts as soon as possible
parents async

no_guarantee_order
content no guarantee on execution order
parents blocks_page

blocks_page
content Blocks page when executing
children no_guarantee_order
parents download_noblock

download_noblock
content Downloads without blocking
children blocks_page
parents async

comments
content comments
children single_line
parents javascript

single_line
content Single Line (//)
parents comments

multiline
content multiline (/* */)
parents javascript