# openapi-form-generator

> React based Dynamic Form Builder

Latest version **0.0.3-d** (published 2021-02-12) · MIT license · 0 weekly downloads

## Install

```sh
npm install openapi-form-generator
pnpm add openapi-form-generator
yarn add openapi-form-generator
bun add openapi-form-generator
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.3-d |
| Published | 2021-02-12 |
| First published | 2018-09-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Unpacked size | 164.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Clayton Barnard |
| Maintainers | chaosren, dusty.roberts |
| Keywords | form, builder, react |

## Links

- npm: https://www.npmjs.com/package/openapi-form-generator
- Repository: https://github.com/Cellfind/form-builder
- Homepage: https://github.com/Cellfind/form-builder#readme
- Issues: https://github.com/Cellfind/form-builder/issues
- npm.io page: https://npm.io/package/openapi-form-generator

## Dependencies (6)

- [axios](https://npm.io/package/axios.md) latest
- [lodash](https://npm.io/package/lodash.md) latest
- [moment](https://npm.io/package/moment.md) latest
- [react-select](https://npm.io/package/react-select.md) 2.4.4
- [humanize-plus](https://npm.io/package/humanize-plus.md) latest
- [react-datetime](https://npm.io/package/react-datetime.md) 2.16.3

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 0.0.3-d (latest) — 2021-02-12
- 0.0.3-c — 2021-02-12
- 0.0.3-b — 2020-12-04
- 0.0.3 — 2020-12-02
- 0.0.2-b — 2020-02-27
- 0.0.2 — 2020-02-27
- 0.0.1 — 2018-09-27

## README

# FormBuilder

[![npm version](https://badge.fury.io/js/openapi-form-generator.svg)](https://badge.fury.io/js/openapi-form-generator)


## How to use:

### Install

```npm i openapi-form-generator```

OR

```yarn add openapi-form-generator```

### Add Props

```
<FormBuilder
    openApiOptions={{
        //Handle Response
        //Optional, but Recommended
        onResponseReceived: (data, response) => { 
            console.log(data); //Response Data Object
            console.log(response); //Full Response with Headers + Status + Status Code
        },

        //Where to find the json file        
        src: '/my/api/v1/swagger.json', 
        baseUrl: 'http://api.website.com/', 
        path: '/api/path/as/in/paths/of/json'
    }}
    
    //Useful for seeing Full Request/Response (Remove in production) 
    debug     
    //TODO: check NODE_ENV if production
/>
```

### :star2:Done!:star2:



## What does it use?:

- DateTime / Date - [react-datetime](https://github.com/YouCanBookMe/react-datetime)
- Enums - [react-select](https://github.com/jedwatson/react-select)


## Form Structure: 

```
<form class="form">
    <div class="field">
        <label class="label"></label>
        <input class="input" /> OR <textarea class="textarea"></textarea>
    </div>
    <br />
    <button class="button"></button>
</form>
```

## Contribution:

To start developing, run:

```npm t```

OR

```npm test```

This will run a test server for the `test-app` folder with hot-reloading etc.

---
_Source: https://npm.io/package/openapi-form-generator · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
