Add IntersectionObserver polyfill

This commit is contained in:
Ines Montani 2019-02-26 12:24:10 +01:00
parent bb2b36f65a
commit 5fdce55a1b
3 changed files with 7 additions and 0 deletions

View File

@ -9914,6 +9914,11 @@
}
}
},
"intersection-observer": {
"version": "0.5.1",
"resolved": "https://registry.npmjs.org/intersection-observer/-/intersection-observer-0.5.1.tgz",
"integrity": "sha512-Zd7Plneq82kiXFixs7bX62YnuZ0BMRci9br7io88LwDyF3V43cQMI+G5IiTlTNTt+LsDUppl19J/M2Fp9UkH6g=="
},
"into-stream": {
"version": "3.1.0",
"resolved": "http://registry.npmjs.org/into-stream/-/into-stream-3.1.0.tgz",

View File

@ -40,6 +40,7 @@
"gatsby-transformer-remark": "^2.2.5",
"gatsby-transformer-sharp": "^2.1.13",
"html-to-react": "^1.3.4",
"intersection-observer": "^0.5.1",
"node-sass": "^4.11.0",
"parse-numeric-range": "0.0.2",
"prismjs": "^1.15.0",

View File

@ -1,6 +1,7 @@
import React, { useEffect } from 'react'
import PropTypes from 'prop-types'
import classNames from 'classnames'
import 'intersection-observer'
import { useInView } from 'react-intersection-observer'
import { window } from 'browser-monads'