@xh/hoist 71.0.0-SNAPSHOT.1736187551916 → 71.0.0-SNAPSHOT.1736188078116

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,7 +21,7 @@ import {fmtDateTime} from '@xh/hoist/format';
21
21
  import {action, bindable, makeObservable, observable, comparer, runInAction} from '@xh/hoist/mobx';
22
22
  import {olderThan, SECONDS} from '@xh/hoist/utils/datetime';
23
23
  import {executeIfFunction, pluralize, throwIf} from '@xh/hoist/utils/js';
24
- import {find, isEqual, isNil, isNull, isUndefined, lowerCase} from 'lodash';
24
+ import {find, isEqual, isNil, isNull, isUndefined, lowerCase, uniqBy} from 'lodash';
25
25
  import {ReactNode} from 'react';
26
26
  import {ViewInfo} from './ViewInfo';
27
27
  import {View} from './View';
@@ -609,7 +609,7 @@ export class ViewManagerModel<T = PlainObject> extends HoistModel {
609
609
  this.pendingValue = pendingValue;
610
610
  // Ensure we update meta-data as well.
611
611
  if (!view.isDefault) {
612
- this.views = this.views.map(v => (v.token === view.token ? view.info : v));
612
+ this.views = uniqBy([view.info, ...this.views], 'token');
613
613
  }
614
614
  }
615
615
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xh/hoist",
3
- "version": "71.0.0-SNAPSHOT.1736187551916",
3
+ "version": "71.0.0-SNAPSHOT.1736188078116",
4
4
  "description": "Hoist add-on for building and deploying React Applications.",
5
5
  "repository": "github:xh/hoist-react",
6
6
  "homepage": "https://xh.io",