import React, {Component, PropTypes} from 'react' import Input from './base/Input'; import Dropdown from './base/Dropdown'; import {METHODS} from '../constants/global'; class UrlInput extends Component { shouldComponentUpdate(nextProps) { return this.props.request.url !== nextProps.request.url; } render () { const {onUrlChange, onMethodChange, request} = this.props; return (
) } } UrlInput.propTypes = { onUrlChange: PropTypes.func.isRequired, onMethodChange: PropTypes.func.isRequired, request: PropTypes.shape({ url: PropTypes.string.isRequired, method: PropTypes.string.isRequired }).isRequired }; export default UrlInput;