atomicojs / react

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

@atomico/react

automatically create containers for React and Preact.

Example auto

import "@atomico/react/proxy"; // stores all customElements.define definitions before import
import { auto } from "@atomico/react";
import WebComponent from "./my-webcomponent";

export const ReactWebComponent = auto(WebComponent);

Example wrapper

import { wrapper } from "@atomico/react";
import WebComponent from "./my-webcomponent";

customElements.defined("web-component", WebComponent);

export const ReactWebComponent = wrapper("my-web-component", WebComponent);

About


Languages

Language:TypeScript 53.0%Language:CSS 25.1%Language:JavaScript 20.4%Language:HTML 1.5%