There are multiple ways of defining methods in Ruby. The most popular is by using a block, via `def` and `end`. One cool thing about Ruby is its **metaprogramming** (being able to write code that writes code) capabilities. As an example, take a look at this `Baby` class definition. ### A Baby example
The `box-sizing` property is used to tell the browser how to calculate the width and height of an element. By default, this is set to `content-box`, which may cause some unexpected behavior for someone new to CSS. `content-box` tells the browser:
Contrary to popular belief, a closure is **not** a function. It is a **combination** of an inner function and its reference to its lexical environment (scope). They allow access to an outer function from an inner function. ### What are inner/outer functions?
Understanding Angular's `$apply` and `$digest` methods require a bit of background on how the browser renders the DOM. The browser has an event loop that will tell it how to display a page. The browser's event loop initiates when any of the three events occur: