setDiff (setAProperty, setBProperty) Ember.ComputedProperty
public
A computed property which returns a new array with all the properties from the first dependent array that are not in the second dependent array.
Example
1 2 3 4 5 6 7 8 9 10 11 12 13 | let Hamster = Ember.Object.extend({ likes: [ 'banana' , 'grape' , 'kale' ], wants: Ember.computed.setDiff( 'likes' , 'fruits' ) }); let hamster = Hamster.create({ fruits: [ 'grape' , 'kale' , ] }); hamster.get( 'wants' ); // ['banana'] |
Parameters:
-
setAProperty
String
-
setBProperty
String
Returns:
-
Ember.ComputedProperty
- computes a new array with all the items from the first dependent array that are not in the second dependent array
Please login to continue.