Nibbling Perfect Macaroni

    practical-react-components-formik
    TypeScript icon, indicating that this package has built-in type declarations

    1.4.0 • Public • Published

    Practical react components formik

    A catalogue of React components that are wrapped by formik, focused on ease-of-use.

    To install the formik package, run:

    yarn add practical-react-components-formik

    This contains all the formik components.

    Dependencies

    Practical react components formik is dependent on some packages, in addition to react and react-dom, that need to be installed for it to work. Make sure the following packages are installed:

    yarn add styled-components
    yarn add react-transition-group
    yarn add pepjs
    yarn add formik

    Usage

    import { useFormik, FormikProvider } from 'formik'
    import { FormikTextInputField } from 'practical-react-components-formik'
    
    const formik = useFormik({
      initialValues,
      validationSchema,
      onSubmit,
    })
    
    return (
      <FormikProvider value={formik}>
        <FormikTextInputField
          label="component-label"
          name="component-name"
          onBlur={formik.submitForm}
        />
      </FormikProvider>
    )

    For more information and example see documentation and formik documentation.

    Keywords

    none

    Install

    npm i practical-react-components-formik

    DownloadsWeekly Downloads

    73

    Version

    1.4.0

    License

    MIT

    Unpacked Size

    94.6 kB

    Total Files

    32

    Last publish

    Collaborators

    • stevenv