react scroll on drag code example
Example: react scrolling a div by dragging the mouse?
import React from 'react';import classNames from 'classnames';import PropTypes from 'prop-types';export class Timeline extends React.PureComponent { render() { const { classes, data, } = this.props; return ( <div ref={this.ref}> <Timeline data={data} /> </div> ); }}Timeline.propTypes = { data: PropTypes.array,};export default Timeline;