Omit loading for Switch

pull/8432/head 3.0.0
Wei Zhu 7 years ago
parent cd1af8b903
commit 44b529b0d5

@ -2,6 +2,7 @@ import * as React from 'react';
import PropTypes from 'prop-types';
import RcSwitch from 'rc-switch';
import classNames from 'classnames';
import omit from 'omit.js';
export interface SwitchProps {
prefixCls?: string;
@ -51,7 +52,7 @@ export default class Switch extends React.Component<SwitchProps, {}> {
});
return (
<RcSwitch
{...this.props}
{...omit(this.props, ['loading'])}
className={classes}
ref={this.saveSwitch}
/>

Loading…
Cancel
Save