flex-render-react
TypeScript icon, indicating that this package has built-in type declarations

0.1.4 • Public • Published

@iamprompt/flex-render

Utility to render LINE Flex Bubble / Carousel JSON for displaying in website.

Installation

pnpm add flex-render-react

Usage

You can input Flex Bubble / Carousel JSON from Flex Message Simulator directly to FlexPreview component.

import 'flex-render-react/css';

import { FlexPreview } from "flex-render-react";

const flexJSON = {
  "type": "bubble",
  "body": {
    "type": "box",
    "layout": "vertical",
    "contents": [
      {
        "type": "text",
        "text": "Brown Cafe",
        "weight": "bold",
        "size": "xl"
      }
    ]
  }
}

<FlexPreview json={flexJSON} />

You can see the example in apps directory.

Bugs

If you find a bug, please file an issue on our issue tracker on GitHub.

/flex-render-react/

    Package Sidebar

    Install

    npm i flex-render-react

    Weekly Downloads

    53

    Version

    0.1.4

    License

    MIT

    Unpacked Size

    91.9 kB

    Total Files

    9

    Last publish

    Collaborators

    • iamprompt