cf-component-link
Advanced tools
Comparing version 1.1.0 to 1.1.1
@@ -33,4 +33,12 @@ 'use strict'; | ||
_initialiseProps.call(_this); | ||
_this.handleClick = function (e) { | ||
e.preventDefault(); | ||
if (_this.props.to) { | ||
(0, _cfUtilRouteHandler.routeTo)(_this.props.to); | ||
} else { | ||
_this.props.onClick(e); | ||
} | ||
}; | ||
return _this; | ||
@@ -82,17 +90,2 @@ } | ||
}; | ||
var _initialiseProps = function _initialiseProps() { | ||
var _this2 = this; | ||
this.handleClick = function (e) { | ||
e.preventDefault(); | ||
if (typeof props.to === 'string') { | ||
(0, _cfUtilRouteHandler.routeTo)(_this2.props.to); | ||
} else { | ||
_this2.props.onClick(e); | ||
} | ||
}; | ||
}; | ||
exports.default = Link; |
{ | ||
"name": "cf-component-link", | ||
"description": "CloudFlare Link Component", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"main": "lib/index.js", | ||
@@ -6,0 +6,0 @@ "scripts": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8180
69