How to use the reactive-mobx-form.reactiveMobxForm function in reactive-mobx-form

To help you get started, we’ve selected a few reactive-mobx-form examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github vict-shevchenko / reactive-mobx-form / src / scripts / examples / sync-validation / SyncFieldValidation.jsx View on Github external
<label>Notes</label>
					<div>
						
					</div>
				

				<section>
					<button disabled="{!valid}" type="submit">Submit</button>
					<button type="button">Reset</button>
				</section>
			
		);
	}
}

const ContactFormReactive = reactiveMobxForm('contacts', {
  schema: {
    firstName: ['', 'required'],
    lastName : ['', 'required'],
    email    : ['', 'required|email'],
  }
})(ContactForm);

export default ContactFormReactive;
github vict-shevchenko / reactive-mobx-form / src / scripts / examples / control-array / ControlArray.jsx View on Github external
return (
			<form>
				<h3>Restaurant food delivery</h3>

				

				<section>
					<button type="submit">Submit</button>
					<button type="button">Reset</button>
				</section>
			
		);
	}
}

const ContactFormReactive = reactiveMobxForm('contacts')(ContactForm);

export default ContactFormReactive;</form>
github vict-shevchenko / reactive-mobx-form / src / scripts / examples / simple / SimpleForm.jsx View on Github external
<label>Notes</label>
					<div>
						
					</div>
				

				<section>
					<button type="submit">Submit</button>
					<button type="button">Reset</button>
				</section>
			
		);
	}
}

const ContactFormReactive = reactiveMobxForm('contacts')(ContactForm);

export default ContactFormReactive;
github vict-shevchenko / reactive-mobx-form / src / ContactForm.jsx View on Github external
<div>
					<label>Accept terms</label>
					
				</div>

				Form Dirty --- {`${dirty}`} <br>
				Form Valid - - {`${valid}`} <br>
				Submit Error  - - {`${JSON.stringify(submitError)}`} <br>
				<button type="submit">Submit</button>  is Submitting - {`${submitting}`} <br>
				<button type="button">Reset</button>
			
		);
	}
}

const ContactFormReactive = reactiveMobxForm('contacts', {
		schema: {
			'lastName': ['shevchenko', 'same:firstName'],
			'email': ['', 'required|email'],
			'acceptTerms': [true],
			'favoriteFilm': ['dieHardwerwe'],
			'sex':[''],
			'job': [''],
			'location.address.city': ['Kyiv', 'required'],
			'perons': [[], 'array']
		},
		validator: {
			errorMessages: {
				'required.location.address.city': 'Yor forgot to specify a :attribute'
			},
			attributeNames: {
				'location.address.city' : 'Your city',
github vict-shevchenko / reactive-mobx-form / src / scripts / examples / control-section / ControlSection.jsx View on Github external
<h2>Seller</h2>
				

				<h2>Buyer</h2>
				

				<section>
					<button type="submit">Submit</button>
					<button type="button">Reset</button>
				</section>
			
		);
	}
}

const ContactFormReactive = reactiveMobxForm('contacts')(ContactForm);

export default ContactFormReactive;

reactive-mobx-form

Reactive forms for React running on MobX

MIT
Latest version published 3 years ago

Package Health Score

42 / 100
Full package analysis