Skip to content

GavinJoyce/ember-reflection

Repository files navigation

ember-reflection

Build Status

Returns an array of defined properties for an Ember object

Questions? Ping me @gavinjoyce

Installation

This is an Ember CLI addon, to install:

npm install ember-reflection --save

Usage Instructions

import Em from 'ember';
import getDefinedProperties from 'ember-reflection/get-defined-properties';

var Cat = Em.Object.extend({
  name: null,
  age: null,
  isOld: Em.computed.gt('age', 10)
});

var sully = Cat.create({
  name: 'Sully',
  age: 4
});

getDefinedProperties(sully); //=> ['name', 'age', 'isOld']

Development Instructions

  • git clone this repository
  • npm install
  • bower install

Running

About

Reflect upon Ember objects

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors