function addFeatureOption(name, kind) {
  if (kind === EXPERIMENTAL)
    experimentalOptions[name] = true;

  Object.defineProperty(parseOptions, name, {
    get: function() {
      return !!options[name];
    },
    enumerable: true,
    configurable: true
  });

  Object.defineProperty(transformOptions, name, {
    get: function() {
      var v = options[name];
      if (v === 'parse')
        return false;
      return v;
    },
    enumerable: true,
    configurable: true
  });

  var defaultValue = options[name] || kind === ON_BY_DEFAULT;
  options[name] = defaultValue;
  defaultValues[name] = defaultValue;
}
function addFeatureOption(name, kind) {
  if (kind === EXPERIMENTAL)
    experimentalOptions[name] = true;

  Object.defineProperty(parseOptions, name, {
    get: function() {
      return !!options[name];
    },
    enumerable: true,
    configurable: true
  });

  Object.defineProperty(transformOptions, name, {
    get: function() {
      var v = options[name];
      if (v === 'parse')
        return false;
      return v;
    },
    enumerable: true,
    configurable: true
  });

  var defaultValue = options[name] || kind === ON_BY_DEFAULT;
  options[name] = defaultValue;
  defaultValues[name] = defaultValue;
}
function addFeatureOption ( name , kind ) { if ( kind === EXPERIMENTAL ) experimentalOptions [ name ] = true ; Object . defineProperty ( parseOptions , name , { get : function ( ) { return ! ! options [ name ] ; } , enumerable : true , configurable : true } ) ; Object . defineProperty ( transformOptions , name , { get : function ( ) { var v = options [ name ] ; if ( v === 'parse' ) return false ; return v ; } , enumerable : true , configurable : true } ) ; var defaultValue = options [ name ] || kind === ON_BY_DEFAULT ; options [ name ] = defaultValue ; defaultValues [ name ] = defaultValue ; }
Adds a feature option.
This also adds a view from the parseOption and the transformOption to the
underlying value.
Adds a feature option . This also adds a view from the parseOption and the transformOption to the underlying value .