Minor stuff

This commit is contained in:
Edin Dazdarevic
2017-04-08 02:32:48 +02:00
parent 027323919e
commit b540f50e15
4 changed files with 9 additions and 13 deletions

View File

@@ -1,5 +1,5 @@
import React from 'react';
import ReactDOM from 'react-dom';
import {findDOMNode} from 'react-dom';
import {formatPrice} from '../lib/helpers';
import {loadListing} from '../lib/api';
@@ -98,12 +98,12 @@ export default class Listings extends React.Component {
}
attachScrollListener () {
const listings = ReactDOM.findDOMNode(this.refs.listings);
const listings = findDOMNode(this.refs.listings);
listings.parentNode.addEventListener('scroll', this.handleScroll);
}
removeScrollListener () {
const listings = ReactDOM.findDOMNode(this.refs.listings);
const listings = findDOMNode(this.refs.listings);
listings.parentNode.removeEventListener('scroll', this.handleScroll);
}