Module

x/aleph/compiler/mod.ts>transform

The Full-stack Framework in Deno.
Very Popular
Go to Latest
function transform
import { transform } from "https://dotland.deno.dev/x/aleph@v0.3.0-alpha.33/compiler/mod.ts";

transform module by swc.

transform(
  '/app.tsx',
  `
    export default App() {
      return <h1>Hello World</h1>
    }
  `,
  {
    url: '/app.tsx'
    swcOptions: {
      target: 'es2020'
    }
  }
)

Parameters

url: string
  • the module URL.
code: string
  • the mocule code.
optional
options: TransformOptions = [UNSUPPORTED]
  • the transform options.