formsy-react/examples
Aesop Wolf 42e39cbc8f Chore/tweaks for v1 (#473)
* Rename HOC/Wrapper export to `withFormsy`

This is more in alignment with community practices.

* Migrate from npm to yarn

* Update package.json

Use order listed on https://yarnpkg.com/en/docs/package-json

* Update README.md

New examples, and small copy/whitespace changes

* Remove CHANGES.md

We will use github release from now on

* Fix test suite

Replace all references to  with

* Add ESLint

* Update dependencies

* Upgrade babel dependencies

* Upgrade jsdom

* Upgrade nodeunit and sinon

* Upgrade webpack and webpack-dev-server

* Fix examples

* Convert to ES6 classes

* Fix ESLint errors and warnings (WIP)

* Fix more ESLint errors and warnings (WIP)

* Move runRules to utils.js

* Fix more ESLint errors and warnings (WIP)

* Fix more ESLint errors and warnings (WIP)

* Fix more ESLint errors and warnings (WIP)

* Use less complex regex's for url and email

* Change grammar in README

* Change export pattern

* Use ES6 export for utils and validationRules

* Fix login example

* Reorder methods alphabetically and remove "magical" `validate` feature

* Remove `validate` from API docs (and general cleanup of file)

* Update examples (removes `validate` feature)

* Rename webpack file and remove json loader

* Fix code samples in README

* Update reset-values example (WIP)

* Cleanup reset-values example

* Fix prop type for Wrapper value

* Handle onReset event

* Update reset-value example to support `<button type="reset">`

* Update dynamic form fields example
2017-08-29 16:35:17 -07:00
..
components Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00
custom-validation Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00
dynamic-form-fields Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00
login Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00
reset-values Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00
.eslintrc Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00
README.md Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00
global.css Added `dynamic form fields` example. 2015-12-01 17:00:43 +03:00
index.html Added `dynamic form fields` example. 2015-12-01 17:00:43 +03:00
webpack.config.js Chore/tweaks for v1 (#473) 2017-08-29 16:35:17 -07:00

README.md

Formsy React Examples

To run and development examples:

  1. Clone this repo
  2. Run npm install
  3. Start the development server with npm run examples
  4. Point your browser to http://localhost:8080

Possible Issues

Examples might not run if you have an old node packages. Try clear npm cache and reinstall dependencies:

rm -rf node_modules
npm cache clean
npm install
npm run examples

If it is not helped try update your node.js and npm.

Examples

  1. Login

    Two required fields with simple validation.

  2. Custom Validation

    One field with added validation rule (addValidationRule) and one field with dynamically added validation and error messages.

  3. Reset Values

    Reset text input, checkbox and select to their pristine values.

  4. Dynamic Form Fields

    Dynamically adding and removing fields to form.