// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle' | |
}); |
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle' | |
}); |
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle', | |
queryParams: ['greeting'] | |
}); |
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle' | |
}); |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>LinkedIn</title> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<style type="text/css"> | |
.iframe #header, | |
.iframe #body, | |
.iframe #footer, |
# Roots of the synchronization | |
root = ssh://{username}@{username}-ld1/workspace | |
root = /Users/{username}/workspace | |
# Paths to synchronize if any | |
# Some regexps specifying names and paths to ignore | |
ignore = Name *.* |
#A Few JavaScript Pointers
###Declaring Variables and Classes In JavaScript
It is really important to follow syntactic conventions to keep your code readable. Variable names should be mixedCase
. In addition you should always name variables in a meaningful way. Try to stay away from names like temp
or other
. Anything that is too vague or non-specific will just make your code really confusing when you look back at it later.
One of the huge uses of variables is that you can name them in such a way that describes what kind of data the variable holds. By reading the variable names throughout your program you can get good idea of what data is being manipulated in different places in your program.
JavaScript is an object oriented language, so we can use objects to model our data after real world things. For example, take people. We can define a class of Person objects and then put the data we have about different people, e.g. their names, into different Person object instances.