Skip to content

Commit 8efc8f3

Browse files
committed
perf(base mixin): only import and use what is necessary from skatejs
Remove unused skatejs mixins: with-children, with-context and with-lifecycle via removing with-component mixin from base.js.
1 parent 4054d4b commit 8efc8f3

File tree

1 file changed

+7
-6
lines changed
  • src/client/scripts/private/mixins

1 file changed

+7
-6
lines changed

src/client/scripts/private/mixins/base.js

+7-6
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
/*************************************
22
* BASE MIXIN (for all rb-components)
33
*************************************/
4-
import { props, withComponent } from '../../../../../skatejs/dist/esnext/index.js';
5-
import { html, render } from '../../../../../lit-html/lit-html.js';
6-
import EventService from '../../private/services/event.js';
7-
import ViewService from '../../private/services/view.js';
8-
import Styles from '../../private/services/styles.js';
4+
import { withRenderer } from '../../../../../skatejs/dist/esnext/with-renderer.js';
5+
import { props, withUpdate } from '../../../../../skatejs/dist/esnext/with-update.js';
6+
import { html, render } from '../../../../../lit-html/lit-html.js';
7+
import EventService from '../../private/services/event.js';
8+
import ViewService from '../../private/services/view.js';
9+
import Styles from '../../private/services/styles.js';
910
Styles.addUtils(); // only runs once
1011

11-
const Base = (BaseElm = HTMLElement) => class extends withComponent(BaseElm) {
12+
const Base = (BaseElm = HTMLElement) => class extends withUpdate(withRenderer(BaseElm)) {
1213
/* Lifecycle
1314
************/
1415
constructor() { // :void

0 commit comments

Comments
 (0)