feat: adding support for jsx

This commit is contained in:
Daniel Ledda
2022-05-26 15:11:17 +02:00
parent 2e8e3c858a
commit 182c38232e
9 changed files with 95 additions and 32 deletions

View File

@@ -1,3 +1,5 @@
import {SubNode} from "./helpers";
export type RungOptions = {};
export default abstract class Rung {
@@ -32,3 +34,5 @@ export default abstract class Rung {
protected abstract build(): HTMLElement;
}
export type FunctionalRung<Props extends Record<string, any>, N extends Node> = (attributes: Props, subNodes: SubNode[]) => N;