Giter Site home page Giter Site logo

cle1000 / react-schema-form-rc-select Goto Github PK

View Code? Open in Web Editor NEW

This project forked from networknt/react-schema-form-rc-select

0.0 2.0 0.0 524 KB

An add-on of react-schema-form that support multiple select and a demo for extending react-schema-form with new components.

License: MIT License

JavaScript 95.74% HTML 4.26%

react-schema-form-rc-select's Introduction

react-schema-form-rc-select

An add-on of react-schema-form that support multiple select and a demo for extending react-schema-form with new components.

Features

  1. Single select or multiple select
  2. Static dropdown values defined in schema or form
  3. Dynamic dropdown values load from server by get or post request
  4. Tagging which means you can add new entries even they are not in the dropdown.
  5. Dynamic dropdown values enriched on the server when schema/form is loaded.(This only works with light framework

To run the example locally

If you don't have babel-cli installed globally, please do it first.

sudo npm install -g babel-cli

Clone the project and run

git clone https://github.com/networknt/react-schema-form-rc-select.git
cd react-schema-form-rc-select
npm install
npm start

Then open localhost:8001 in a browser.

Installation

npm install react-schema-form-rc-select

This module is an extension of react-schema-form and it must be called from react-schema-form to handle rc-select form type. It shows how to customize react-schema-form to add a new field and map a new form type to it. Please see ExamplePage.js for the details.

require('rc-select/assets/index.css');
import RcSelect from 'react-schema-form-rc-select/lib/RcSelect';

...

        var schemaForm = '';
        if (this.state.form.length > 0) {
            schemaForm = (
                <SchemaForm schema={this.state.schema} form={this.state.form} model={this.state.model} onModelChange={this.onModelChange} mapper={{"rc-select": RcSelect}} />
            );
        }

Contributing

See our CONTRIBUTING.md for information on how to contribute.

License

MIT Licensed. Copyright (c) Network New Technologies Inc. 2016.

react-schema-form-rc-select's People

Contributors

devel-pa avatar stevehu avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.