react-i13n
Advanced tools
Comparing version 2.0.7 to 2.0.8
@@ -15,3 +15,3 @@ /** | ||
var I13nUtils = require('./I13nUtils'); | ||
var listen = require('subscribe-ui-event/dist/lib/listen'); | ||
var listen = require('subscribe-ui-event').listen; | ||
var ReactI13n = require('../libs/ReactI13n'); | ||
@@ -220,2 +220,17 @@ var ViewportMixin = require('./viewport/ViewportMixin'); | ||
/** | ||
* _shouldFollowLink, provide a hook to check followLink. | ||
* It check if component implement its own shouldFollowLink() method, | ||
* otherwise return props.followLink or props.follow | ||
* @method _shouldFollowLink | ||
* @private | ||
*/ | ||
_shouldFollowLink: function () { | ||
if (undefined !== this.shouldFollowLink) { | ||
return this.shouldFollowLink(); | ||
} | ||
return (undefined !== props.followLink) ? props.followLink : props.follow; | ||
}, | ||
/** | ||
* _subComponentsViewportDetection, will be executed by viewport mixin | ||
@@ -222,0 +237,0 @@ * @method _subComponentsViewportDetection |
@@ -58,3 +58,3 @@ /** | ||
var props = self.props; | ||
var followLink = (undefined !== props.followLink) ? props.followLink : props.follow; | ||
var followLink = self._shouldFollowLink(); | ||
var href = ''; | ||
@@ -61,0 +61,0 @@ |
@@ -6,3 +6,3 @@ /** | ||
/* global document, window*/ | ||
var listen = require('subscribe-ui-event/dist/lib/listen'); | ||
var listen = require('subscribe-ui-event').listen; | ||
@@ -9,0 +9,0 @@ var uniqueId = 0; |
{ | ||
"name": "react-i13n", | ||
"description": "React I13n provides a performant and scalable solution to application instrumentation.", | ||
"version": "2.0.7", | ||
"version": "2.0.8", | ||
"main": "index.js", | ||
@@ -19,3 +19,3 @@ "repository": { | ||
"setimmediate": "^1.0.2", | ||
"subscribe-ui-event": "^1.0.3" | ||
"subscribe-ui-event": "^1.0.5" | ||
}, | ||
@@ -22,0 +22,0 @@ "devDependencies": { |
74728
1778
Updatedsubscribe-ui-event@^1.0.5