Installing FormKit Pro is easy! Here are the steps:
Login to your FormKit Pro account at pro.formkit.com and create a project. A Project Key
will be provided to you.
Next, install the @formkit/pro
:
npm install @formkit/pro
Import the createProPlugin
helper and any desired Pro Inputs from @formkit/pro
:
// main.js or formkit.config.ts
import { createProPlugin, rating, toggle } from '@formkit/pro'
// Create the Pro plugin with your `Project Key` and desired Pro Inputs:
const proPlugin = createProPlugin('fk-00000000000', {
rating,
toggle,
// any other Pro Inputs
})
// add the plugin to your FormKit config:
const config = defaultConfig({
plugins: [proPlugin],
})
If you are using the legacy Genesis CSS theme, then follow the instructions below.
Note: All Tailwind themes from themes.formkit.com ship with support for Pro Inputs, so the instructions below are not required for Tailwind users.
If you are using the legacy Genesis CSS theme, you will need to install the accompanying Pro CSS as well:
// main.js or formkit.config.ts
// Genesis for Pro is dependent on Genesis
import '@formkit/themes/genesis'
import '@formkit/pro/genesis'