Skip to content

Commit f4081ae

Browse files
pshrmntimdorr
authored andcommitted
Polyfill Element for Node (#6607)
* Polyfill Element for Node * Adds missing "const" keyword to Element (#6609)
1 parent 065950c commit f4081ae

File tree

1 file changed

+2
-0
lines changed
  • packages/react-router-dom/modules

1 file changed

+2
-0
lines changed

packages/react-router-dom/modules/Link.js

+2
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,8 @@ class Link extends React.Component {
5959

6060
if (__DEV__) {
6161
const toType = PropTypes.oneOfType([PropTypes.string, PropTypes.object]);
62+
// polyfill for Node
63+
const Element = typeof Element === "undefined" ? function() {} : Element;
6264
const innerRefType = PropTypes.oneOfType([
6365
PropTypes.string,
6466
PropTypes.func,

0 commit comments

Comments
 (0)