wunphile
Version:
Simple, imperative JavaScript-based static site generator
25 lines (22 loc) • 551 B
JavaScript
import { html } from '../../../../index.mjs'
import { Layout } from '../Layout.mjs'
import { Counter } from '../Counter.ts'
/** @import { Component } from '../../../../index.mjs' */
/**
* The index page component.
* @type {Component<void, void>}
*/
export const IndexPage = (_) => {
return Layout({}, html`
<h1>Hi!</h1>
<p>List of names:</p>
<ul>
${['John', 'James', 'Jim'].map(name => html`
<li>${name}</li>
`)}
</ul>
<br/>
${Counter({ initial: 1 })}
<p>Next, go to the <a href="/about/">about</a> page.</p>
`)
}