@symbiotejs/symbiote 2.0.2 → 2.0.3

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.
package/README.md CHANGED
@@ -68,7 +68,7 @@ The easiest way to try Symbiote.js is to create a simple `html` file in your tex
68
68
 
69
69
  ```html
70
70
  <script type="module">
71
- import { Symbiote, html } from 'https://symbiotejs.github.io/symbiote.js/core/Symbiote.js';
71
+ import Symbiote, { html } from 'https://symbiotejs.github.io/symbiote.js/core/Symbiote.js';
72
72
 
73
73
  class MyComponent extends Symbiote {
74
74
  init$ = {
@@ -97,12 +97,6 @@ Check the project documentation for details:
97
97
  * [symbiotejs.org](https://symbiotejs.org/)
98
98
  * [Docs on GitHub](https://github.com/symbiotejs/docsite/tree/main/md)
99
99
 
100
- ## 🤖 Live examples
101
- Browser: https://symbiotejs.github.io/examples/
102
- > Use devtools to discover details
103
-
104
- GitHub: https://github.com/symbiotejs/examples
105
-
106
100
  ## ✅ Browser support
107
101
  Symbiote.js is supported and tested in all major modern desktop and mobile browsers:
108
102
  * Chrome
package/core/PubSub.js CHANGED
@@ -50,6 +50,10 @@ export class PubSub {
50
50
  /** @type {Function} */
51
51
  let compFn = this.store[prop];
52
52
  if (!this.__computedSet) {
53
+ /**
54
+ * @private
55
+ * @type {Set<String>}
56
+ */
53
57
  this.__computedSet = new Set();
54
58
  }
55
59
  this.__computedSet.add(prop);
package/core/Symbiote.js CHANGED
@@ -621,11 +621,13 @@ export class Symbiote extends HTMLElement {
621
621
 
622
622
  /** @param {String | CSSStyleSheet} styles */
623
623
  static set rootStyles(styles) {
624
+ this.rootStyleSheets = [];
624
625
  this.addRootStyles(styles);
625
626
  }
626
627
 
627
628
  /** @param {String | CSSStyleSheet} styles */
628
629
  static set shadowStyles(styles) {
630
+ this.shadowStyleSheets = [];
629
631
  this.addShadowStyles(styles);
630
632
  }
631
633
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@symbiotejs/symbiote",
4
- "version": "2.0.2",
4
+ "version": "2.0.3",
5
5
  "scripts": {
6
6
  "types": "tsc -p dts.cfg.json"
7
7
  },
@@ -33,7 +33,7 @@ declare module "core/PubSub" {
33
33
  store: any;
34
34
  callbackMap: Record<keyof T, Set<(val: unknown) => void>>;
35
35
  read(prop: keyof T): any;
36
- __computedSet: Set<any>;
36
+ private __computedSet;
37
37
  has(prop: string): any;
38
38
  add(prop: string, val: unknown, rewrite?: boolean): void;
39
39
  pub(prop: keyof T, val: unknown): void;
@@ -126,6 +126,7 @@ declare module "core/Symbiote" {
126
126
  renderShadow: boolean;
127
127
  readyToDestroy: boolean;
128
128
  processInnerHtml: boolean;
129
+ ssrMode: boolean;
129
130
  allowCustomTemplate: boolean;
130
131
  ctxOwner: boolean;
131
132
  isVirtual: boolean;