25 lines
1.1 KiB
Org Mode
25 lines
1.1 KiB
Org Mode
|
* 3 new
|
||
|
** Window.location
|
||
|
Can find information about window's current URL, for example,
|
||
|
window.location.hostname will be the URL's hostname.
|
||
|
** HTML pauses loading while fetching javascript
|
||
|
Developers tend to load external JavaScript files at the end of the html
|
||
|
in an attempt to avoid pausing the loading of HTML
|
||
|
** Async and defer attributes
|
||
|
Able to load web page concurrently with loading and processing
|
||
|
JavaScript with async attribute.
|
||
|
|
||
|
Defer allows it all to load together, but waits until the end to
|
||
|
process the JavaScript
|
||
|
* 2 interesting
|
||
|
** Web pages written before defer and async attributes
|
||
|
Many web pages could load faster if they implemented these attributes
|
||
|
** Javascirpt minification
|
||
|
Javascript can be minified in order to lower the size of the file.
|
||
|
The interesting bit, is that it can do things like replacing long
|
||
|
variable names with short ones.
|
||
|
* 1 unclear
|
||
|
One little thing about APIs. Are they just public functions? I imagine them as either public functions that are used directly (like a library), or public functions that are activated by sending messages from one program to another.
|
||
|
|
||
|
|