Actions
Feature #21563
closedInclude babel-plugin-transform-class-properties so we can use static class variables
Description
In order to do things like this:
class RedHatRepositoriesPage extends Component { static defaultProps = { redHatRepositoriesResponse: {}, redHatRepositorySetsResponse: {} }; static propTypes = { loadRedHatRepositories: PropTypes.func.isRequired, loadRedHatRepositorySets: PropTypes.func.isRequired, redHatRepositoriesResponse: PropTypes.object, redHatRepositorySetsResponse: PropTypes.object }; ... }
We need the babel plugin babel-plugin-transform-class-properties. To me, the above is clearer than:
class ChartBox extends React.Component { ... } ChartBox.PropTypes = { status: PropTypes.string.isRequired, config: PropTypes.object, modalConfig: PropTypes.object, id: PropTypes.string.isRequired, noDataMsg: PropTypes.string, errorText: PropTypes.string };
Updated by The Foreman Bot about 7 years ago
- Status changed from New to Ready For Testing
- Pull request https://github.com/theforeman/foreman/pull/4975 added
Updated by Walden Raines about 7 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset 60c09ae4106e8a418828edec9e6e28c482893af4.
Updated by Ohad Levy about 7 years ago
- Translation missing: en.field_release set to 296
Actions