@crave/farmblocks-hoc-input

A High Order Component that adds behaviour of label support, different styles for focus and errors, and validation error messages.

Stats

stars 🌟issues ⚠️updated 🛠created 🐣size 🏋️‍♀️
2023Jun 15, 2021Aug 23, 2017Minified + gzip package size for @crave/farmblocks-hoc-input in KB

Readme

Farmblocks Input HOC

A High Order Component that adds behaviour of label support, different styles for focus and errors, and validation error messages.

Installation

npm install @crave/farmblocks-hoc-input

Usage

import formInput from "@crave/farmblocks-hoc-input";
const FbInput = formInput(props => React.createElement("input", props));
const Form = () => <FbInput label="Label" placeholder="Helpful placeholder" />;

For more examples and details on the available props, read the docs.

License

MIT

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.