Skip to content

Instantly share code, notes, and snippets.

@rwaldron

rwaldron/at-names.js

Created Sep 24, 2012
Embed
What would you like to do?
at-names for real private data in ES6
function C() {
this.foo = "a foo";
this.@bar = "a private at-name!";
}
var c = new C();
console.log(c);
/*
{ foo: "a foo" }
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment