4.9.2 - 2026-06-12
- Fix a regression introduced in 4.9.1, where types weren't exported correctly
4.9.1 - 2026-06-10
- Revert the
CacheDatatype alias back to an augmentableinterface - Avoid collisions in hook ids
4.9.0 - 2026-05-08
- Allow ignoring visits from hook handlers
4.8.3 - 2026-02-24
- Remove
postinstallscript to prevent warnings when installing swup via pnpm
4.8.2 - 2025-04-29
- Fix
matchPathto treat an empty array like an empty string
4.8.1 - 2024-09-28
- Fix usage of combined hook options
onceandreplace
4.8.0 - 2024-09-25
- Add
hooksoption to allow registering all hooks at once - Add
visit.metakey for custom data
4.7.0 - 2024-07-18
- Inherit
data-swup-*attributes from parent elements - Store current location as object at
swup.location - Deprecate
swup.currentPageUrlin favor ofswup.location.url - Make previous page's hash available at
visit.from.hash
4.6.1 - 2024-03-26
- Reduce bundle size by eliminating unused code paths
4.6.0 - 2024-02-09
- Provide access to the parsed document through
visit.to.document
4.5.2 - 2024-01-27
- Fix reflow helper being optimized away during build step
4.5.1 - 2024-01-08
- Wait with transition class mutations when pausing before
content:replace - Ignore errors in user hooks
4.5.0 - 2023-12-01
- Support View Transitions API in new native mode
- Handle rapid link clicks to achieve smooth transitions
- Abort superseded visits with new
visit:aborthook
4.4.4 - 2023-11-17
- Dispatch DOM event
swup:anyevery time a hook is run - Allow listening to DOM events from the
window - Improve working with DOM events in TypeScript
4.4.3 - 2023-11-16
- Improve compatibility with older Safari versions
4.4.2 - 2023-09-28
- Export types for hook handlers and return values
4.4.1 - 2023-09-25
- Fix multiple rapid clicks on links
4.4.0 - 2023-09-19
- Enable experimental View Transition support
- Extend test coverage to all major browsers
- Add request timeout option
4.3.4 - 2023-08-24
- Add unique id to visit object
4.3.3 - 2023-08-21
- Restore history index on reload
4.3.2 - 2023-08-20
- Update history entry on links to the current page
4.3.1 - 2023-08-17
- Improve scroll restoration on history visits
4.3.0 - 2023-08-16
- Persist elements across page loads using
data-swup-persist - Add
visit.cachekey to control cache behavior - Enforce parameter and return types of hook handlers
4.2.0 - 2023-08-09
- Add option
linkToSelfto control behavior for links to the current page - Don't create history records for repeated visits to the current page
- Allow updating
visit.to.hashandvisit.scroll.targetseparately
4.1.0 - 2023-07-29
- Prevent unintentional cache mutation
- Use recommended order for package.json exports
- Infer element type from delegate selector
4.0.1 - 2023-07-28
- Export additional types to allow augmentation from plugins
4.0.0 - 2023-07-26
See the release notes and upgrade guide for details.
- Built-in scroll support
- New hook system for customizing the page load lifecycle
- Context object for controlling the transition process
- Animation scope: add animation classes to html element or to containers
- Easier customization of official themes
- Allow pruning cache entries
- Hooks replace events:
swup.hooks.on() - Use the
visitargument in hooks instead ofswup.transition - Container selectors now only match one single element per selector
- Custom animation attribute renamed to
data-swup-animation - Swup no longer adds
data-swupattributes to containers - Navigation method renamed:
swup.navigate() - Simplified cache API:
cache.set() - Support for custom payload formats was dropped
3.1.1 - 2023-06-23
- Accept
#topas special scroll target
3.1.0 - 2023-06-13
- Allow replacing the current history entry instead of pushing to it
3.0.8 - 2023-06-04
- Create smaller bundle for modern browsers
- Make warning about missing transitions less strict
3.0.7 - 2023-05-26
- Update event delegation library
- Fix edge case in detecting transition events
- Improve selection of scroll anchor targets
3.0.6 - 2023-04-06
- Fix
exportsfield in package.json - Fully qualify imports to support TypeScript
moduleResolution: node16 - Switch to Vitest for unit tests
3.0.5 - 2023-03-02
- Ensure correct
Refererrequest header
3.0.4 - 2023-01-29
- Clarify/improve event typings for Swup event handlers
3.0.3 - 2023-01-27
- Use shared browserslist config
3.0.2 - 2023-01-20
- Make sure ignoreVisit option is called when visiting pages programmatically
3.0.1 - 2023-01-20
- Fix: remove origin from ignoreVisit parameter
3.0.0 - 2023-01-19
- Support CSS animations and keyframes
- Allow ignoring visits via callback function
- Rewritten in TypeScript
- Export typings and native ESM modules
- Smaller bundle size for modern browsers: 4.5 kB
- Improved test coverage
See upgrade instructions for details.
- Swup will now wait for the longest transitioned property
- Swup will no longer add
to-*classes for the next URL - UMD and CDN bundle names have changed
- Import paths for helpers have changed
2.0.19 - 2022-08-23
- Gracefully handle missing document title
- Disable caching of initial page to avoid caching modified DOM
- Force-reload if next page has no swup containers
- Remove all reliance on global window.swup instance
2.0.18 - 2022-08-09
- Fix buggy behavior when navigating rapidly between pages
2.0.17 - 2022-08-01
- Gracefully handle missing transitions on container
- Warn about missing container
- Scope transition selector to body
- Normalize cache paths
2.0.16 - 2022-06-30
- Improve handling of scroll anchors with special characters (@knokmki612)
2.0.15 - 2022-06-14
- Update dependencies (@fregante)
- Improve test coverage (@daun)
2.0.14 - 2020-12-27
- Update readme
2.0.13 - 2020-12-06
- Update readme
2.0.12 - 2020-11-29
- Fix bug where animateHistoryBrowsing option was ignored for OUT animations
2.0.11 - 2020-07-09
- Update readme
2.0.10 - 2020-06-07
- Test autopublish feature
2.0.9 - 2020-06-07
- Ensure removal of popstate handler on destroy
- Implement end-to-end tests
- Fix issue where
bodytext is interpreted as tag
- Update readme
- Add funding information
- Restore IE10 support
- Fix build script error
- Update readme
- Fix import filenames
- Update readme
- Update readme
- Create plugin system to slim down core library
- Extract previous core functionality into plugins
- Simplify support check and make it required
- Allow setting custom request headers
- Rename selector option to containers
- Restructure project repository
- Return promise when preloading pages
- Ignore clicks when special key pressed
- Implement event handler system
- Allow setting custom transition via data attribute
- Trigger events for animation start
- Display final url after redirects
- Enable animated history visits
- Change default link selector and animation class
- Improve server error handling
- Update readme
- Update readme
- Improve IE/Edge compatibility
- Remove manual browser detection
- Initial release