Skip to content

Automatic forms and validation with redux-form using antd

License

Notifications You must be signed in to change notification settings

dgonz64/redux-form-auto-antd

Repository files navigation

redux-form-auto-antd

redux-form-auto-antd allows your React application to automatically generate forms and validation code using ReduxForm for state management and Ant Design for component rendering. It uses redux-form-antd to manage ReduxForm field connection.

It extends redux-form-auto and the API is identical (documentation).

Watch a demo

Demo

Installation

$ npm install redux-form-auto-antd --save

Usage

Just like redux-form-auto except you import this one. You are also in charge of importing antd.

    import { Schema } from 'redux-form-auto-antd'

    const client = new Schema('client', {
      name: {
        type: 'string',
        required: true,
        max: 32
      },
      age: {
        type: 'number'
      }
    })

    const MyForm = ({ onSubmit }) =>
      <Autoform
        schema={client}
        onSubmit={onSubmit}
      />

About

Automatic forms and validation with redux-form using antd

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages