👀📎 It looks like you're preparing to MC a conference...
🚨 GIANT DISCLAIMER: This stuff is far from authoritative. But it's what I think works for me, and what I enjoy in an MC when I'm attending a conference.
@mixin valid-quantity($quantity) { | |
@if type-of($quantity) != 'number' { | |
@error 'The "quantity" parameter must be a number!'; | |
} | |
@if not(unitless($quantity)) { | |
@error 'The "quantity" parameter must not have a unit!'; | |
} | |
@if $quantity < 0 { | |
@error 'The "quantity" parameter must be at least 0!'; | |
} |
[based on a true story]
So. Your friend's about to teach you how to make a website. Great!
You make a file, and you save it as 'index.html'. Why it's called 'index' isn't really explained to you, but whatever.
You type the following.
hello world
.force-show-scrollbars ::-webkit-scrollbar-track:vertical { | |
border-left: 1px solid #E7E7E7; | |
box-shadow: 1px 0 1px 0 #F6F6F6 inset, -1px 0 1px 0 #F6F6F6 inset; | |
} | |
.force-show-scrollbars ::-webkit-scrollbar-track:horizontal { | |
border-top: 1px solid #E7E7E7; | |
box-shadow: 0 1px 1px 0 #F6F6F6 inset, 0 -1px 1px 0 #F6F6F6 inset; | |
} |
This guide assumes you have the emmet
and language-babel
packages already installed in Atom
keymap.cson
file by clicking on Atom -> Keymap…
in the menu bar'atom-text-editor[data-grammar~="jsx"]:not([mini])':
on alfred_script(q) | |
tell application "Google Chrome" to activate -- needs to be in front | |
tell application "System Events" to tell application process "Chrome" | |
try | |
repeat with x from 1 to (count windows) | |
get properties of window x | |
set position of window x to {0, 21} | |
set size of window x to {1280, 709} | |
end repeat | |
end try |
The following are a few important npm packages.
Core Babel and access to Babel:
babel-core
: the core compilation machinery and plugin infrastructure for Babel. You will rarely need to install this package, because other packages such as babel-cli
have it as a dependency, meaning that it will be automatically installed when they are installed.
babel-cli
: a command line interface to Babel
. It includes the following commands:
babel-doctor
detects common problems with your Babel installation.
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