Skip to content

Commit

Permalink
Expose our DDF renderer and constants as an alias for other engines
Browse files Browse the repository at this point in the history
  • Loading branch information
skateman committed Apr 29, 2020
1 parent b063402 commit b6822b1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/javascript/forms/data-driven-form.jsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import PropTypes from 'prop-types';
import { Form } from 'patternfly-react';
import FormRender, { Validators, layoutComponents } from '@data-driven-forms/react-form-renderer';
import FormRender, { Validators, layoutComponents, componentTypes, validatorTypes } from '@data-driven-forms/react-form-renderer';
import { layoutMapper } from '@data-driven-forms/pf3-component-mapper';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
Expand Down Expand Up @@ -60,4 +60,5 @@ MiqFormRenderer.defaultProps = {

const mapDispatchToProps = dispatch => bindActionCreators({ setPristine }, dispatch);

export { componentTypes, validatorTypes };
export default connect(null, mapDispatchToProps)(MiqFormRenderer);
1 change: 1 addition & 0 deletions config/webpack/shared.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ module.exports = {
'bootstrap-select': '@pf3/select', // never use vanilla bootstrap-select
'@patternfly/patternfly': resolveModule('NONEXISTENT'),
'@patternfly/patternfly-next': resolveModule('NONEXISTENT'),
'@@MiQ-DDF': resolve(dirname(__filename), '../../app/javascript/forms/data-driven-form'),
},
extensions: settings.extensions,
modules: [],
Expand Down

0 comments on commit b6822b1

Please sign in to comment.