catberry
Version:
Catberry is an isomorphic framework for building universal front-end apps using components, Flux architecture and progressive rendering.
20 lines (17 loc) • 412 B
JavaScript
;
module.exports = {
/**
* Defines a read-only property.
* @param {Object} object The object to define a property in.
* @param {string} name The name of the property.
* @param {*} value The value of the property.
*/
defineReadOnly: (object, name, value) => {
Object.defineProperty(object, name, {
enumerable: false,
configurable: false,
writable: false,
value
});
}
};