Closed mvestnik closed 7 months ago
Please add preact support
Test component:
import { render, Component } from "https://esm.sh/preact@10.20.2" export class Test extends Component { render() { return ( <> <button>Post</button> </> ) } } render(<Test />, document.getElementById("#test"))
Esbuild config:
import * as esbuild from "https://deno.land/x/esbuild@v0.20.2/mod.js" import { denoPlugins } from "https://deno.land/x/esbuild_deno_loader@0.9.0/mod.ts" const context = await esbuild.context({ plugins: [...denoPlugins()], entryPoints: ["frontend/app/*.tsx"], jsx: "automatic", jsxImportSource: "preact", bundle: true, minify: true, format: "esm", outdir: "static/js", }) await context.watch()
Result:
Please add preact support
Test component:
Esbuild config:
Result: