Infinite Scroll v4 released
11 Jan 2021
This week, I released the new major version of Infinite Scroll, v4. New features include:
- fetch() API makes requests
loadNextPage
returns a PromisefetchOptions
set headers and fetch options- 15% smaller filesize
- ES2018 syntax and features
Give Infinite Scroll v4 a look right here.
Infinite Scroll v4 is largely backwards compatible with v3. Upgrading to v4 is no sweat. Breaking changes include:
- replaced
responseType
option withresponseBody
. This effects loading JSON. - Internet Explorer and Android 4 support dropped.
- Removed RequireJS support and AMD export.
A lot of work went into improving the infrastructure around around the plugin. JS code is linted with ESLint. Testing is now done via command line with Puppeteer. Both these improvements allow for automated testing with GitHub Actions, allowing for integrated testing on commits and Pull Requests (take a look at the workflows/nodejs.yml
).
Infinite Scroll is the oldest piece of software I support, dating back to Paul Irish’s original release in 2008. Not many software companies can boast that kind of longevity. I’m proud to be able to keep it going all these years.
I chose to upgrade Infinite Scroll as it is less popular, making it a good testing ground for new development. I’ve laid the groundwork to start tackling the bigger plugins next: Isotope & Flickity.