Skip to main content
Module

x/lume/tests/__snapshots__/jsx_preact.test.ts.snap

πŸ”₯ Static site generator for Deno πŸ¦•
Very Popular
Go to Latest
File
export const snapshot = {};
snapshot[`build a site with jsx/tsx modules using Preact 1`] = `6`;
snapshot[`build a site with jsx/tsx modules using Preact 2`] = `{ formats: [ { engines: 1, ext: ".tmpl.ts", pageLoader: [AsyncFunction: module], }, { engines: 1, ext: ".tmpl.js", pageLoader: [AsyncFunction: module], }, { engines: undefined, ext: ".tmpl.json", pageLoader: [AsyncFunction: json], }, { dataLoader: [AsyncFunction: json], engines: undefined, ext: ".json", }, { engines: 1, ext: ".md", pageLoader: [AsyncFunction: text], }, { componentLoader: [AsyncFunction: module], dataLoader: [AsyncFunction: module], engines: 1, ext: ".js", }, { componentLoader: [AsyncFunction: module], dataLoader: [AsyncFunction: module], engines: 1, ext: ".ts", }, { componentLoader: [AsyncFunction: text], engines: 1, ext: ".njk", includesPath: "_includes", pageLoader: [AsyncFunction: text], }, { dataLoader: [AsyncFunction: yaml], engines: undefined, ext: ".yaml", pageLoader: [AsyncFunction: yaml], }, { dataLoader: [AsyncFunction: yaml], engines: undefined, ext: ".yml", pageLoader: [AsyncFunction: yaml], }, { componentLoader: [AsyncFunction: module], engines: 1, ext: ".jsx", pageLoader: [AsyncFunction: module], }, { componentLoader: [AsyncFunction: module], engines: 1, ext: ".tsx", pageLoader: [AsyncFunction: module], }, ],}`;
snapshot[`build a site with jsx/tsx modules using Preact 3`] = `[]`;
snapshot[`build a site with jsx/tsx modules using Preact 4`] = `{ content: "<html><head><title>This is the title</title></head><body><main><h1>Hello world</h1><p>This is a JSX page</p></main></body></html>", data: { comp: {}, content: undefined, date: 1970-01-01T00:00:00.000Z, layout: "layout.jsx", page: undefined, paginate: [Function: paginate], search: Search {}, tags: [ ], title: "This is the title", url: "/", }, dest: { ext: ".html", path: "/index", }, src: { ext: ".jsx", path: "/index", remote: undefined, },}`;
snapshot[`build a site with jsx/tsx modules using Preact 5`] = `{ content: "<html><head><title></title></head><body><main><div>1</div></main></body></html>", data: { comp: {}, content: undefined, date: 1970-01-01T00:00:00.000Z, layout: "layout.jsx", page: undefined, paginate: [Function: paginate], search: Search {}, tags: [ ], url: "/page/1/", }, dest: { ext: ".html", path: "/page/1/index", }, src: { ext: ".jsx", path: "/multiple[0]", remote: undefined, },}`;
snapshot[`build a site with jsx/tsx modules using Preact 6`] = `{ content: "<html><head><title></title></head><body><main><div>2</div></main></body></html>", data: { comp: {}, content: undefined, date: 1970-01-01T00:00:00.000Z, layout: "layout.jsx", page: undefined, paginate: [Function: paginate], search: Search {}, tags: [ ], url: "/page/2/", }, dest: { ext: ".html", path: "/page/2/index", }, src: { ext: ".jsx", path: "/multiple[1]", remote: undefined, },}`;
snapshot[`build a site with jsx/tsx modules using Preact 7`] = `{ content: '<html><head><title>Markdown combined with JSX</title></head><body><main><div><h1>Hello <strong class="foo">world</strong></h1><p>This is a <strong>markdown</strong> text. <a href="/">Go home</a></p><p><button type="foo">Hello</button></p><img src="foo" /><div class="hello">Hello world</div></div></main></body></html>', data: { comp: {}, content: 'import Hello from "./_includes/hello.jsx";# Hello <strong className="foo">world</strong>
This is a **markdown** text. [Go home](/)
<comp.Button type="foo" /><img src="foo" /><Hello>Hello world</Hello>', date: 1970-01-01T00:00:00.000Z, layout: "layout.jsx", page: undefined, paginate: [Function: paginate], search: Search {}, tags: [ ], templateEngine: "jsx,md", title: "Markdown combined with JSX", url: "/pseudo-mdx/", }, dest: { ext: ".html", path: "/pseudo-mdx/index", }, src: { ext: ".md", path: "/pseudo-mdx", remote: undefined, },}`;
snapshot[`build a site with jsx/tsx modules using Preact 8`] = `{ content: '<html><head><title>This is the title</title></head><body><main><h1>This is the title</h1><p>This is a JSX page <a href="/blog/">Go to home</a></p></main></body></html>', data: { comp: {}, content: undefined, date: 1970-01-01T00:00:00.000Z, layout: "layout.jsx", page: undefined, paginate: [Function: paginate], search: Search {}, tags: [ ], title: "This is the title", url: "/with-function/", }, dest: { ext: ".html", path: "/with-function/index", }, src: { ext: ".jsx", path: "/with-function", remote: undefined, },}`;
snapshot[`build a site with jsx/tsx modules using Preact 9`] = `{ content: '<html><head><title>Markdown combined with JSX</title></head><body><main><div><h1 class="foo">Hello world</h1><p>This is a <strong>markdown</strong> text. <a href="/">Go home</a></p><pre><code class="language-css">body { color: blue;}</code></pre></div></main></body></html>', data: { comp: {}, content: "# Hello world{.foo}This is a **markdown** text. [Go home](/)
\`\`\`cssbody { color: blue;}\`\`\`", date: 1970-01-01T00:00:00.000Z, layout: "layout.jsx", page: undefined, paginate: [Function: paginate], search: Search {}, tags: [ ], title: "Markdown combined with JSX", url: "/with-markdown/", }, dest: { ext: ".html", path: "/with-markdown/index", }, src: { ext: ".md", path: "/with-markdown", remote: undefined, },}`;