htmx
Fluent UI Emoji for htmx — a
tiny server handler that serves emoji SVG fragments for htmx to swap in.
3,145 emojis in flat, high-contrast, and modern styles.
Install
Section titled “Install”pnpm add @fluentui-emoji/htmxServer (Express, or plain node:http):
import express from 'express';import {fluentEmojiHandler} from '@fluentui-emoji/htmx';
const app = express();app.use(fluentEmojiHandler()); // GET /fluentui-emoji/:style/:slug?label=...Page:
<span hx-get="/fluentui-emoji/flat/rocket" hx-trigger="load"></span><span hx-get="/fluentui-emoji/modern/party-popper?label=Party!" hx-trigger="load"></span>Responses are sent with immutable cache headers. There’s also a direct helper
for template engines: await emojiHtml('rocket', 'flat', 'Rocket').