/Wiki/sources/honojs__hono/2026/https-hono-dev-llms-full-txt-css-62b2af18fbab-css-s0695-c0000.md

`css` - hono-docs

css Source evidence: /Sources/raw/honojs hono/honojs hono.md Canonical citation: https://hono.dev/llms full.txt css Summary You can write CSS in the css temp...

css

Source evidence: /Sources/raw/honojshono/honojshono.md Canonical citation: https://hono.dev/llms-full.txt#css

Summary

You can write CSS in the css template literal. In this case, it uses headerClass as a value of the class attribute. Don't forget to add as it contains the CSS content. ``ts{10,13} app.get('/', (c) => { const headerClass = css...

Content

You can write CSS in the css template literal. In this case, it uses headerClass as a value of the class attribute. Don't forget to add <Style /> as it contains the CSS content.

app.get('/', (c) => {
  const headerClass = css`
    background-color: orange;
    color: white;
    padding: 1rem;
  `
  return c.html(
    <html>
      <head>
        <Style />
      </head>
      <body>
        <h1 class={headerClass}>Hello!</h1>
      </body>
    </html>
  )
})

You can style pseudo-classes like :hover by using the nesting selector, &:

const buttonClass = css`
  background-color: #fff;
  &:hover {
    background-color: red;
  }
`
Kinic Wiki
Loading knowledge node
Details

Identity

database
db_23dhmsxlhukv
database_id
db_23dhmsxlhukv
path
/Wiki/sources/honojs__hono/2026/https-hono-dev-llms-full-txt-css-62b2af18fbab-css-s0695-c0000.md
kind
directory
role
markdown_note
children
0

Metadata

created_at
virtual
updated_at
virtual
etag
virtual
metadata_json
{}

Lint Hints

No lightweight warnings.

Outgoing Links

No outgoing links indexed.

Incoming Links

Select a file node to inspect backlinks.

Raw Source

No raw source path inferred.