-
-
Save poteto/b022b7a3a59ba087bc34f11673d1b6d0 to your computer and use it in GitHub Desktop.
freeze-it
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
const setReadOnly = (context, name, value) => { | |
const writable = false; | |
const configurable = false; | |
const enumerable = true; | |
Ember.defineProperty(context, name, { value, writable, configurable, enumerable }); | |
}; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle', | |
init() { | |
setReadOnly(this, 'foo', 'bar'); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": "0.9.1", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"options": { | |
"use_pods": false, | |
"enable-testing": false | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js", | |
"ember": "2.6.0", | |
"ember-data": "2.6.0", | |
"ember-template-compiler": "2.6.0" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment