Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/docxml/src/utilities/jsx.ts>jsx

TypeScript library for parsing and building a DOCXML file
Go to Latest
function jsx
import { jsx } from "https://deno.land/x/docxml@5.1.1/src/utilities/jsx.ts";

The JSX pragma with which you can write <Paragraph> instead of new Paragraph({}).

Also exposed as the jsx prop on the (static) class as well as instance of this library's top- level API -- see also Api.

Parameters

component: ComponentComponentFunction<C> | ComponentDefinition<C>
...children: Array<ComponentChild<C> | Array<ComponentChild<C>>>

Returns

Promise<Array<C | ComponentChild<C> | ReturnType<ComponentComponentFunction<C>>>>