Skip to content

Instantly share code, notes, and snippets.

@kettanaito
Last active April 3, 2018 13:16
Show Gist options
  • Save kettanaito/0c61af08162309db86e98e8a2a01d4a0 to your computer and use it in GitHub Desktop.
Save kettanaito/0c61af08162309db86e98e8a2a01d4a0 to your computer and use it in GitHub Desktop.
React Advanced Form - App
// app/index.js
import React from 'react';
import ReactDOM from 'react-dom';
import { FormProvider } from 'react-advanced-form';
import rules from './validation-rules';
import messages from './validation-messages';
import Root from './Root';
const renderApp = () => (
<FormProvider rules={rules} messages={messages}>
<Root />
</FormProvider>
);
ReactDOM.render(renderApp, document.getElementById('root'));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment