Skip to content

Instantly share code, notes, and snippets.

@daytonn
Last active August 29, 2015 14:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save daytonn/0d2dba80a131bdcc49f1 to your computer and use it in GitHub Desktop.
Save daytonn/0d2dba80a131bdcc49f1 to your computer and use it in GitHub Desktop.
CWCPOOJS - class
function Person(attributes) {
this.firstName = attributes.firstName;
this.lastName = attributes.lastName;
this.age = attributes.age;
this.address = attributes.address;
}
var bob = new Person({
firstName: "Bob",
lastName: "Ject",
age: 33,
address: {
street: "123 Memory Ln",
apt: "0x7fff9575c05f",
zip: "01101",
city: "Browser Town",
state: "Mozilla"
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment