0.0.6 • Published 3 years ago

simplestateform v0.0.6

Weekly downloads
13
License
ISC
Repository
github
Last release
3 years ago

SimpleStateForm

Library for creating easy simple forms in React.

Basic Usage

import SimpleStateFrom from 'SimpleStateForm'

export default Form {

    constructor(props) {
        super(props)

        this.form = SimpleStateForm({
            component: this,
            schema: {
                email: {
                    initial: "",
                    validate: (value) => {
                        if (value.length === 0) return "Email is required"
                    }
                }
            }
        })

        this.state = {
            ...this.form.initialValues
        }

    }

}
0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago