- How the browser renders the document
- Receives the data (bytes) from the server.
- Parses and converts into tokens (<, TagName, Attribute, AttributeValue, >).
- Turns tokens into nodes.
- Turns nodes into the
DOMtree.
- Builds
CSSOMtree from thecss rules.
All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.
Generally, all APIs that synchronously provide layout metrics will trigger forced reflow / layout. Read on for additional cases and details.
elem.offsetLeft,elem.offsetTop,elem.offsetWidth,elem.offsetHeight,elem.offsetParent
| var colorArray = ['#FF6633', '#FFB399', '#FF33FF', '#FFFF99', '#00B3E6', | |
| '#E6B333', '#3366E6', '#999966', '#99FF99', '#B34D4D', | |
| '#80B300', '#809900', '#E6B3B3', '#6680B3', '#66991A', | |
| '#FF99E6', '#CCFF1A', '#FF1A66', '#E6331A', '#33FFCC', | |
| '#66994D', '#B366CC', '#4D8000', '#B33300', '#CC80CC', | |
| '#66664D', '#991AFF', '#E666FF', '#4DB3FF', '#1AB399', | |
| '#E666B3', '#33991A', '#CC9999', '#B3B31A', '#00E680', | |
| '#4D8066', '#809980', '#E6FF80', '#1AFF33', '#999933', | |
| '#FF3380', '#CCCC00', '#66E64D', '#4D80CC', '#9900B3', | |
| '#E64D66', '#4DB380', '#FF4D4D', '#99E6E6', '#6666FF']; |
Copyright (c) 2018 Ryan Carpenter
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
(from Understanding Nginx Server and Location Block Selection Algorithms - https://goo.gl/YyzshP)
server {
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
