jQuery notes
How to select things and modify them:
$("#css_selector").prop("some_html_attribute", "value")
Examples:
isAuthenticated = ...;
$("btn-logout").prop("disabled", !isAuthenticated);
if (isAuthenticated) {
$("#content").css('visibility', 'visible')
}
else {
$("#content").css('visibility', 'hidden')
}
Life and computer hacks
Life hacks:
Computer hacks:
Why build single-page apps over multi-page apps
After stumbling upon the use of jQuery (see: jQuery notes), I became intrigued by the prospect of building single-page apps, in which the DOM is manipulated directly by jQuery/JavaScript.
Some research into why we would want to build single page apps, and why we wouldn't.
From Ruby Garage
Quoting from Wikipedia:
The goal is faster transitions that make the website feel more like a native app.