added ref to FeatureSet to .features of built object...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2017-07-02 17:17:29 +03:00
parent f90a2797d7
commit 91af35d72c
2 changed files with 21 additions and 3 deletions

View File

@ -898,11 +898,27 @@ var FeatureSetProto = {
// -> actions
//
//
// This will add .unapplicable to the output of .buildFeatureList(..)
// and to .features of the resulting object...
// This will set .features on the object.
//
// .features format:
// {
// // the current feature set object...
// FeatureSet: feature-set,
//
// // list of features not applicable in current context...
// //
// // i.e. the features that defined .isApplicable(..) and it
// // returned false when called.
// unapplicable: [ feature-tag, .. ],
//
// // output of .buildFeatureList(..)...
// ...
// }
//
// NOTE: this will store the build result in .features of the output
// actions object.
// NOTE: .features is reset even if a FeatureLinearizationError error
// is thrown.
setup: function(obj, lst){
// no explicit object is given...
if(lst == null){
@ -954,6 +970,8 @@ var FeatureSetProto = {
&& console.error('Hit loop limit while sorting dependencies!')
}
features.FeatureSet = this
obj.features = features
// fatal error -- can't load...

View File

@ -1,6 +1,6 @@
{
"name": "ig-features",
"version": "3.1.11",
"version": "3.2.0",
"description": "",
"main": "features.js",
"scripts": {