Sha256: 11e64372f90da94829b70397321e12d1d6b3eb99149a6f389585acf859310f92

Contents?: true

Size: 1000 Bytes

Versions: 4

Compression:

Stored size: 1000 Bytes

Contents

import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { BrowserRouter as Router } from 'react-router-dom';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';

import * as actions from '../../scenes/Organizations/OrganizationActions';
import reducer from '../../scenes/Organizations/OrganizationReducer';
import Routes from './Routes';
import './overrides.scss';

const mapStateToProps = state => ({ organization: state.organization });
const mapDispatchToProps = dispatch => bindActionCreators(actions, dispatch);

export const organization = reducer;

class Application extends Component {
  componentDidMount() {
    this.loadData();
  }

  loadData() {
    this.props.loadOrganization();
  }

  render() {
    return (
      <Router>
        <Routes />
      </Router>
    );
  }
}

Application.propTypes = {
  loadOrganization: PropTypes.func.isRequired,
};

export default connect(mapStateToProps, mapDispatchToProps)(Application);

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
katello-3.7.0 webpack/containers/Application/index.js
katello-3.8.0.rc1 webpack/containers/Application/index.js
katello-3.7.0.rc2 webpack/containers/Application/index.js
katello-3.7.0.rc1 webpack/containers/Application/index.js