src/Morearty.js
function (newState, newMetaState, options) {
      var args = Util.resolveArgs(
        arguments,
        'newState', function (x) { return Imm.Map.isMap(x) ? 'newMetaState' : null; }, '?options'
      );

      var effectiveOptions = args.options || {};

      var tx = this.getBinding().atomically();
      tx.set(newState);

      if (args.newMetaState) tx.set(this.getMetaBinding(), args.newMetaState);

      tx.commit({ notify: effectiveOptions.notify });
    }
function (newState, newMetaState, options) {
      var args = Util.resolveArgs(
        arguments,
        'newState', function (x) { return Imm.Map.isMap(x) ? 'newMetaState' : null; }, '?options'
      );

      var effectiveOptions = args.options || {};

      var tx = this.getBinding().atomically();
      tx.set(newState);

      if (args.newMetaState) tx.set(this.getMetaBinding(), args.newMetaState);

      tx.commit({ notify: effectiveOptions.notify });
    }
function ( newState , newMetaState , options ) { var args = Util . resolveArgs ( arguments , 'newState' , function ( x ) { return Imm . Map . isMap ( x ) ? 'newMetaState' : null ; } , '?options' ) ; var effectiveOptions = args . options || { } ; var tx = this . getBinding ( ) . atomically ( ) ; tx . set ( newState ) ; if ( args . newMetaState ) tx . set ( this . getMetaBinding ( ) , args . newMetaState ) ; tx . commit ( { notify : effectiveOptions . notify } ) ; }
Replace whole state with new value.
@param {Immutable.Map} newState new state
@param {Immutable.Map} [newMetaState] new meta state
@param {Object} [options] options object
@param {Boolean} [options.notify=true] should listeners be notified
Replace whole state with new value .