themesberg / flowbite

Open-source UI component library and front-end development framework based on Tailwind CSS
https://flowbite.com
MIT License
7.98k stars 746 forks source link

How do i differentiate between free and paid plans when using in a project? #951

Closed user4302 closed 2 months ago

user4302 commented 2 months ago

i cant seem to find any documentation.

currently trying to add and use the pro blocks in a suncel app

i found this in one gpt response but this wont work as @suncel/ui/flowbite-pro is undefined and how do i even assign logic to isPro in this example if this is the correct path?

import { MenuBlockSchema } from "@suncel/nextjs";
import { TitleAndSub } from "./blocks/hero/titleAndSub";
import flowbiteBlocks from "@suncel/ui/flowbite";
import flowbiteProBlocks from "@suncel/ui/flowbite-pro";

export const menuBlocks: MenuBlockSchema[] = [
  flowbiteBlocks,
  {
    category: "Page blocks",
    blocks: [
      {
        name: "Hero",
        variants: [
          {
            image: "https://assets.suncel.io/61bf5e233c962a862faf209f/title_and_sub_comp.png",
            component: TitleAndSub,
            name: "Title And Sub Hero",
            description: "A simple title and one optional subtitle",
          },
          ...(isPro ? [flowbiteProBlocks] : []),
        ],
      },
    ],
  },
];

// Example conditional logic to check if the user has a pro subscription plan
const isPro = // logic to check if the user has a pro subscription plan
zoltanszogyenyi commented 2 months ago

Hey there,

Best way is to check our pricing page:

https://flowbite.com/pro/#pricing

user4302 commented 2 months ago

Hey there,

Best way is to check our pricing page:

https://flowbite.com/pro/#pricing

just to clarify, after purchasing, do i download the pro files and add them to my suncel app manually and import them?