diff --git a/.gitignore-backup b/.gitignore-backup deleted file mode 100644 index 49feedd..0000000 --- a/.gitignore-backup +++ /dev/null @@ -1,9 +0,0 @@ -node_modules -.sass-cache -npm-debug.log -.idea -dist -lib -tmp -coverage -0.md diff --git a/README.md b/README.md index 3ca2aae..7076d6b 100644 --- a/README.md +++ b/README.md @@ -70,7 +70,7 @@ See [here](https://github.com/jasonsalzman/react-add-to-calendar/blob/master/doc I'll do my best to stay compatible with the latest version of React. I can't guarantee support for all older versions of React. Latest compatible versions: -- React 15.0.0 or newer +- React 15.5.0 or newer ### Browser Support diff --git a/package.json b/package.json index 2f604d8..29e0c83 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "author": "Jason Salzman", "name": "react-add-to-calendar", "description": "A simple and reusable add to calendar button component for React", - "version": "0.1.0", + "version": "0.1.1", "license": "MIT", "homepage": "https://github.com/jasonsalzman/react-add-to-calendar", "repository": { diff --git a/src/ReactAddToCalendar.js b/src/ReactAddToCalendar.js index 012507c..529ff27 100644 --- a/src/ReactAddToCalendar.js +++ b/src/ReactAddToCalendar.js @@ -18,6 +18,14 @@ export default class ReactAddToCalendar extends React.Component { } componentWillMount() { + // polyfill for startsWith to fix IE bug + if (!String.prototype.startsWith) { + String.prototype.startsWith = function(searchString, position) { + position = position || 0; + return this.indexOf(searchString, position) === position; + }; + } + let isCrappyIE = false; if ( typeof window !== "undefined" && @@ -217,4 +225,4 @@ ReactAddToCalendar.defaultProps = { { yahoo: "Yahoo" } ], rootClass: "react-add-to-calendar" -}; +}; \ No newline at end of file