From 75ffafc355d7e335676b748629aceb22603674c3 Mon Sep 17 00:00:00 2001 From: Joe Lencioni Date: Thu, 12 Nov 2015 09:18:18 -0800 Subject: [PATCH] 1.1.2 - Fix built version --- CHANGELOG.md | 4 ++++ build/npm/waypoint.js | 9 +++++++++ package.json | 2 +- 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4942c8f..813c4a1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ ## master (unreleased) +## 1.1.2 + +- Fix built version + ## 1.1.1 - Add statics for edge argument used by `onEnter` and `onLeave` diff --git a/build/npm/waypoint.js b/build/npm/waypoint.js index 73e253b..536ca9b 100644 --- a/build/npm/waypoint.js +++ b/build/npm/waypoint.js @@ -25,6 +25,11 @@ var Waypoint = React.createClass({ onLeave: PropTypes.func }, + statics: { + above: POSITIONS.above, + below: POSITIONS.below + }, + /** * @return {Object} */ @@ -102,6 +107,10 @@ var Waypoint = React.createClass({ * called by a React lifecyle method */ _handleScroll: function _handleScroll(event) { + if (!this.isMounted()) { + return; + } + var currentPosition = this._currentPosition(); var previousPosition = this._previousPosition || null; diff --git a/package.json b/package.json index 8d26800..bf9c140 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-waypoint", - "version": "1.1.1", + "version": "1.1.2", "description": "A React component to execute a function whenever you scroll to an element.", "main": "build/npm/waypoint.js", "repository": {