無料ツール

    Intlayer メッセージフォーマッター&エディター

    {{var}}補間、t()、plural()、enu()、select()、cond()、Markdownを使用して型安全なIntlayerコンテンツ宣言を作成、テスト、検証します。

    テンプレート18
    INTLAYER エディター
    有効な構文
    36 文字1

    テスト変数とライブプレビュー

    変数を調整し言語を切り替えてCLDR複数形ルールを確認します

    言語:
    出力結果 (en):
    Hello Alex, welcome to Intlayer!
    Intlayer の型安全な宣言にエクスポート
    import { type Dictionary } from 'intlayer';const convertedMessageContent = {  key: 'converted-message',  content: 'Hello {{name}}, welcome to Intlayer!',} satisfies Dictionary;export default convertedMessageContent;
    Intlayerは完全なTypeScript自動補完によりコンパイル時に翻訳を検証します。

    Intlayer Message Format Syntax Cheat Sheet

    構文ルールとIntlayerの型安全な宣言へのマッピング一覧

    機能構文備考Intlayer での同等表現
    Variable Interpolation{{variableName}}Hello {{name}}!Double curly braces for dynamic parameter insertionuseIntlayer(key).name or resolveMessage()
    Multilingual Translationt({ en: "...", fr: "..." })t({ en: "Hello", fr: "Bonjour" })Locale-keyed translations with type safety and fallbackt({ [locale]: string })
    Pluralization (plural)plural({ one: "...", other: "..." })plural({ one: "1 item", other: "{{count}} items" })CLDR cardinal plural rules with automatic count lookupplural({ [category]: string })
    Exact Enumeration (enu)enu({ 0: "...", 1: "...", fallback: "..." })enu({ 0: "Zero", 1: "One", fallback: "{{count}}" })Exact numeric matching with fallback for remaining countsenu({ [number]: string, fallback })
    Dynamic Selection (select)select({ key: "...", fallback: "..." }, "variable")select({ admin: "Admin", fallback: "User" }, "role")Branch on any custom string variable discriminatorselect({ [key]: string }, variableKey)
    Gender Agreement (gender)gender({ male: "...", female: "...", fallback: "..." })gender({ male: "He", female: "She", fallback: "They" })Grammatical gender concordance with automatic lookupgender({ male, female, fallback })
    Boolean Condition (cond)cond({ true: "...", false: "..." })cond({ true: "Logged In", false: "Guest" })Evaluates boolean state conditionscond({ true: string, false: string })
    Markdown Content (md)md("# ...\n**bold**")md("# Title\n\n**Bold** {{variable}}")Rich markdown rendered to React / HTML nodesmd(markdownString)
    Embedded HTML (html)html("<tag>...</tag>")html("<p>Visit <a href=\"/\">home</a></p>")Embedded safe HTML markup for links and formattinghtml(htmlString)
    Intlayerのコンパイラ駆動アーキテクチャは、複雑な実行時パースをコンパイル時の型安全性と自動抽出に置き換えます。
    Intlayer エコシステム

    複雑な構文に悩まされることはもうありません

    Intlayerは、コンパイル時の型安全性、自動コンポーネント抽出、シームレスなCMS統合により、国際化を快適な開発体験に変えます。