v0.2.3
fix: remove $State debug message
This commit is contained in:
parent
7f8f599b8a
commit
72f617df3c
@ -2,18 +2,18 @@ export interface $StateOption<T> {
|
||||
format: (value: T) => string;
|
||||
}
|
||||
export class $State<T> {
|
||||
readonly value: T;
|
||||
readonly value!: T;
|
||||
readonly attributes = new Map<Object, Set<string | number | symbol>>();
|
||||
options: Partial<$StateOption<T>> = {}
|
||||
constructor(value: T, options?: $StateOption<T>) {
|
||||
this.value = value;
|
||||
this.set(value);
|
||||
if (options) this.options = options;
|
||||
}
|
||||
set(value: T) {
|
||||
(this as Mutable<$State<T>>).value = value;
|
||||
// update element content for eatch attributes
|
||||
for (const [node, attrList] of this.attributes.entries()) {
|
||||
for (const attr of attrList) {
|
||||
console.debug(node, attr)
|
||||
//@ts-expect-error
|
||||
if (node[attr] instanceof Function) {
|
||||
//@ts-expect-error
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "elexis",
|
||||
"description": "Build Web in Native JavaScript Syntax",
|
||||
"version": "0.2.2",
|
||||
"version": "0.2.3",
|
||||
"author": {
|
||||
"name": "defaultkavy",
|
||||
"email": "defaultkavy@gmail.com",
|
||||
|
Loading…
Reference in New Issue
Block a user