docs: update readme and TODO comment

This commit is contained in:
Ayo 2022-10-24 10:59:43 +02:00
parent 819d6e4526
commit 6ac9100a2f
2 changed files with 9 additions and 7 deletions

View file

@ -24,12 +24,12 @@
| Packages | Version | Description | | Packages | Version | Description |
| --- | --- | --- | | --- | --- | --- |
| [@astro-reactive/form](https://github.com/ayoayco/astro-reactive-library/blob/main/packages/form/README.md) | [![npm](https://img.shields.io/npm/v/@astro-reactive/form)](https://www.npmjs.com/package/@astro-reactive/form) | a dynamic form which can be modified programmatically | | [form](https://github.com/ayoayco/astro-reactive-library/blob/main/packages/form/README.md) | [![npm](https://img.shields.io/npm/v/@astro-reactive/form)](https://www.npmjs.com/package/@astro-reactive/form) | a dynamic form which can be modified programmatically |
| [@astro-reactive/validator](https://github.com/ayoayco/astro-reactive-library/blob/main/packages/validator/README.md)| [![npm](https://img.shields.io/npm/v/@astro-reactive/validator)](https://www.npmjs.com/package/@astro-reactive/validator) | set up validators for your form easily | | [validator](https://github.com/ayoayco/astro-reactive-library/blob/main/packages/validator/README.md)| [![npm](https://img.shields.io/npm/v/@astro-reactive/validator)](https://www.npmjs.com/package/@astro-reactive/validator) | set up validators for your form easily |
| @astro-reactive/themes | 🛠 | easy-to-use, accessible, consistent cross-browser styles | | themes | 🛠 | easy-to-use, accessible, consistent cross-browser styles |
| @astro-reactive/data-grid | 🛠 | a dynamic data grid of values | | data-grid | 🛠 | a dynamic data grid of values |
| @astro-reactive/charts | 🛠 | data visualization that emits and responds to events | | charts | 🛠 | data visualization that emits and responds to events |
| @astro-reactive/maps | 🛠 | geographic data visualization that emits and responds to events | | maps | 🛠 | geographic data visualization that emits and responds to events |
# HACKTOBERFEST 2022 # HACKTOBERFEST 2022

View file

@ -51,7 +51,9 @@ export class FormControl {
this._placeholder = placeholder; this._placeholder = placeholder;
this._validators = validators; this._validators = validators;
// TODO: implement independence, form should not import validator // TODO: implement independence
// form should try to import validator,
// but handle error when it's not installed
import('@astro-reactive/validator').then((validator) => { import('@astro-reactive/validator').then((validator) => {
if (validator) { if (validator) {
this.validate = validator.validate; this.validate = validator.validate;