Debian Codegraph @

CHANGELOG.md

raw
1 # Changelog
2
3 ## [4.8.3] - 2026-02-24
4
5 - Remove `postinstall` script to prevent warnings when installing swup via pnpm
6
7 ## [4.8.2] - 2025-04-29
8
9 - Fix `matchPath` to treat an empty array like an empty string
10
11 ## [4.8.1] - 2024-09-28
12
13 - Fix usage of combined hook options `once` and `replace`
14
15 ## [4.8.0] - 2024-09-25
16
17 - Add `hooks` option to allow registering all hooks at once
18 - Add `visit.meta` key for custom data
19
20 ## [4.7.0] - 2024-07-18
21
22 - Inherit `data-swup-*` attributes from parent elements
23 - Store current location as object at `swup.location`
24 - Deprecate `swup.currentPageUrl` in favor of `swup.location.url`
25 - Make previous page's hash available at `visit.from.hash`
26
27 ## [4.6.1] - 2024-03-26
28
29 - Reduce bundle size by eliminating unused code paths
30
31 ## [4.6.0] - 2024-02-09
32
33 - Provide access to the parsed document through `visit.to.document`
34
35 ## [4.5.2] - 2024-01-27
36
37 - Fix reflow helper being optimized away during build step
38
39 ## [4.5.1] - 2024-01-08
40
41 - Wait with transition class mutations when pausing before `content:replace`
42 - Ignore errors in user hooks
43
44 ## [4.5.0] - 2023-12-01
45
46 - Support View Transitions API in new native mode
47 - Handle rapid link clicks to achieve smooth transitions
48 - Abort superseded visits with new `visit:abort` hook
49
50 ## [4.4.4] - 2023-11-17
51
52 - Dispatch DOM event `swup:any` every time a hook is run
53 - Allow listening to DOM events from the `window`
54 - Improve working with DOM events in TypeScript
55
56 ## [4.4.3] - 2023-11-16
57
58 - Improve compatibility with older Safari versions
59
60 ## [4.4.2] - 2023-09-28
61
62 - Export types for hook handlers and return values
63
64 ## [4.4.1] - 2023-09-25
65
66 - Fix multiple rapid clicks on links
67
68 ## [4.4.0] - 2023-09-19
69
70 - Enable experimental View Transition support
71 - Extend test coverage to all major browsers
72 - Add request timeout option
73
74 ## [4.3.4] - 2023-08-24
75
76 - Add unique id to visit object
77
78 ## [4.3.3] - 2023-08-21
79
80 - Restore history index on reload
81
82 ## [4.3.2] - 2023-08-20
83
84 - Update history entry on links to the current page
85
86 ## [4.3.1] - 2023-08-17
87
88 - Improve scroll restoration on history visits
89
90 ## [4.3.0] - 2023-08-16
91
92 - Persist elements across page loads using `data-swup-persist`
93 - Add `visit.cache` key to control cache behavior
94 - Enforce parameter and return types of hook handlers
95
96 ## [4.2.0] - 2023-08-09
97
98 - Add option `linkToSelf` to control behavior for links to the current page
99 - Don't create history records for repeated visits to the current page
100 - Allow updating `visit.to.hash` and `visit.scroll.target` separately
101
102 ## [4.1.0] - 2023-07-29
103
104 - Prevent unintentional cache mutation
105 - Use recommended order for package.json exports
106 - Infer element type from delegate selector
107
108 ## [4.0.1] - 2023-07-28
109
110 - Export additional types to allow augmentation from plugins
111
112 ## [4.0.0] - 2023-07-26
113
114 See the [release notes](https://swup.js.org/announcements/swup-4/) and
115 [upgrade guide](https://swup.js.org/getting-started/upgrading/) for details.
116
117 ### Features
118
119 - Built-in scroll support
120 - New hook system for customizing the page load lifecycle
121 - Context object for controlling the transition process
122 - Animation scope: add animation classes to html element or to containers
123 - Easier customization of official themes
124 - Allow pruning cache entries
125
126 ### Breaking changes
127
128 - Hooks replace events: `swup.hooks.on()`
129 - Use the `visit` argument in hooks instead of `swup.transition`
130 - Container selectors now only match one single element per selector
131 - Custom animation attribute renamed to `data-swup-animation`
132 - Swup no longer adds `data-swup` attributes to containers
133 - Navigation method renamed: `swup.navigate()`
134 - Simplified cache API: `cache.set()`
135 - Support for custom payload formats was dropped
136
137 ## [3.1.1] - 2023-06-23
138
139 - Accept `#top` as special scroll target
140
141 ## [3.1.0] - 2023-06-13
142
143 - Allow replacing the current history entry instead of pushing to it
144
145 ## [3.0.8] - 2023-06-04
146
147 - Create smaller bundle for modern browsers
148 - Make warning about missing transitions less strict
149
150 ## [3.0.7] - 2023-05-26
151
152 - Update event delegation library
153 - Fix edge case in detecting transition events
154 - Improve selection of scroll anchor targets
155
156 ## [3.0.6] - 2023-04-06
157
158 - Fix `exports` field in package.json
159 - Fully qualify imports to support TypeScript `moduleResolution: node16`
160 - Switch to Vitest for unit tests
161
162 ## [3.0.5] - 2023-03-02
163
164 - Ensure correct `Referer` request header
165
166 ## [3.0.4] - 2023-01-29
167
168 - Clarify/improve event typings for Swup event handlers
169
170 ## [3.0.3] - 2023-01-27
171
172 - Use shared browserslist config
173
174 ## [3.0.2] - 2023-01-20
175
176 - Make sure ignoreVisit option is called when visiting pages programmatically
177
178 ## [3.0.1] - 2023-01-20
179
180 - Fix: remove origin from ignoreVisit parameter
181
182 ## [3.0.0] - 2023-01-19
183
184 - Support CSS animations and keyframes
185 - Allow ignoring visits via callback function
186 - Rewritten in TypeScript
187 - Export typings and native ESM modules
188 - Smaller bundle size for modern browsers: 4.5 kB
189 - Improved test coverage
190
191 ### Breaking changes
192
193 See [upgrade instructions](https://swup.js.org/getting-started/upgrading-v3/) for details.
194
195 - Swup will now wait for the longest transitioned property
196 - Swup will no longer add `to-*` classes for the next URL
197 - UMD and CDN bundle names have changed
198 - Import paths for helpers have changed
199
200 ## [2.0.19] - 2022-08-23
201
202 - Gracefully handle missing document title
203 - Disable caching of initial page to avoid caching modified DOM
204 - Force-reload if next page has no swup containers
205 - Remove all reliance on global window.swup instance
206
207 ## [2.0.18] - 2022-08-09
208
209 - Fix buggy behavior when navigating rapidly between pages
210
211 ## [2.0.17] - 2022-08-01
212
213 - Gracefully handle missing transitions on container
214 - Warn about missing container
215 - Scope transition selector to body
216 - Normalize cache paths
217
218 ## [2.0.16] - 2022-06-30
219
220 - Improve handling of scroll anchors with special characters (@knokmki612)
221
222 ## [2.0.15] - 2022-06-14
223
224 - Update dependencies (@fregante)
225 - Improve test coverage (@daun)
226
227 ## [2.0.14] - 2020-12-27
228
229 - Update readme
230
231 ## [2.0.13] - 2020-12-06
232
233 - Update readme
234
235 ## [2.0.12] - 2020-11-29
236
237 - Fix bug where animateHistoryBrowsing option was ignored for OUT animations
238
239 ## [2.0.11] - 2020-07-09
240
241 - Update readme
242
243 ## [2.0.10] - 2020-06-07
244
245 - Test autopublish feature
246
247 ## [2.0.9] - 2020-06-07
248
249 - Ensure removal of popstate handler on destroy
250 - Implement end-to-end tests
251
252 ## 2.0.8 - 2019-11-01
253
254 - Fix issue where `body` text is interpreted as tag
255
256 ## 2.0.7 - 2019-09-23
257
258 - Update readme
259
260 ## 2.0.6 - 2019-09-23
261
262 - Add funding information
263
264 ## 2.0.5 - 2019-07-14
265
266 - Restore IE10 support
267 - Fix build script error
268
269 ## 2.0.4 - 2019-05-30
270
271 - Update readme
272
273 ## 2.0.3 - 2019-05-30
274
275 - Fix import filenames
276
277 ## 2.0.2 - 2019-05-26
278
279 - Update readme
280
281 ## 2.0.1 - 2019-05-26
282
283 - Update readme
284
285 ## 2.0.0 - 2019-05-26
286
287 - Create plugin system to slim down core library
288 - Extract previous core functionality into plugins
289 - Simplify support check and make it required
290 - Allow setting custom request headers
291 - Rename selector option to containers
292 - Restructure project repository
293
294 ## 1.9.0 - 2019-02-03
295
296 - Return promise when preloading pages
297
298 ## 1.8.0 - 2019-02-03
299
300 - Ignore clicks when special key pressed
301
302 ## 1.7.0 - 2018-10-28
303
304 - Implement event handler system
305
306 ## 1.6.0 - 2018-10-28
307
308 - Allow setting custom transition via data attribute
309
310 ## 1.5.0 - 2018-10-25
311
312 - Trigger events for animation start
313
314 ## 1.4.0 - 2018-10-12
315
316 - Display final url after redirects
317
318 ## 1.3.0 - 2018-10-08
319
320 - Enable animated history visits
321
322 ## 1.2.0 - 2018-09-23
323
324 - Change default link selector and animation class
325
326 ## 1.1.0 - 2018-09-14
327
328 - Improve server error handling
329
330 ## 1.0.4 - 2018-09-07
331
332 - Update readme
333
334 ## 1.0.3 - 2018-09-07
335
336 - Update readme
337
338 ## 1.0.2 - 2018-09-04
339
340 - Improve IE/Edge compatibility
341
342 ## 1.0.1 - 2018-08-26
343
344 - Remove manual browser detection
345
346 ## 1.0.0 - 2018-08-26
347
348 - Initial release
349
350 [4.8.3]: https://github.com/swup/swup/releases/tag/4.8.3
351 [4.8.2]: https://github.com/swup/swup/releases/tag/4.8.2
352 [4.8.1]: https://github.com/swup/swup/releases/tag/4.8.1
353 [4.8.0]: https://github.com/swup/swup/releases/tag/4.8.0
354 [4.7.0]: https://github.com/swup/swup/releases/tag/4.7.0
355 [4.6.1]: https://github.com/swup/swup/releases/tag/4.6.1
356 [4.6.0]: https://github.com/swup/swup/releases/tag/4.6.0
357 [4.5.2]: https://github.com/swup/swup/releases/tag/4.5.2
358 [4.5.1]: https://github.com/swup/swup/releases/tag/4.5.1
359 [4.5.0]: https://github.com/swup/swup/releases/tag/4.5.0
360 [4.4.4]: https://github.com/swup/swup/releases/tag/4.4.4
361 [4.4.3]: https://github.com/swup/swup/releases/tag/4.4.3
362 [4.4.2]: https://github.com/swup/swup/releases/tag/4.4.3
363 [4.4.1]: https://github.com/swup/swup/releases/tag/4.4.1
364 [4.4.0]: https://github.com/swup/swup/releases/tag/4.4.0
365 [4.3.4]: https://github.com/swup/swup/releases/tag/4.3.4
366 [4.3.3]: https://github.com/swup/swup/releases/tag/4.3.3
367 [4.3.2]: https://github.com/swup/swup/releases/tag/4.3.2
368 [4.3.1]: https://github.com/swup/swup/releases/tag/4.3.1
369 [4.3.0]: https://github.com/swup/swup/releases/tag/4.3.0
370 [4.2.0]: https://github.com/swup/swup/releases/tag/4.2.0
371 [4.1.0]: https://github.com/swup/swup/releases/tag/4.1.0
372 [4.0.1]: https://github.com/swup/swup/releases/tag/4.0.1
373 [4.0.0]: https://github.com/swup/swup/releases/tag/4.0.0
374 [3.1.1]: https://github.com/swup/swup/releases/tag/3.1.1
375 [3.1.0]: https://github.com/swup/swup/releases/tag/3.1.0
376 [3.0.8]: https://github.com/swup/swup/releases/tag/3.0.8
377 [3.0.7]: https://github.com/swup/swup/releases/tag/3.0.7
378 [3.0.6]: https://github.com/swup/swup/releases/tag/3.0.6
379 [3.0.5]: https://github.com/swup/swup/releases/tag/3.0.5
380 [3.0.4]: https://github.com/swup/swup/releases/tag/3.0.4
381 [3.0.3]: https://github.com/swup/swup/releases/tag/3.0.3
382 [3.0.2]: https://github.com/swup/swup/releases/tag/3.0.2
383 [3.0.1]: https://github.com/swup/swup/releases/tag/3.0.1
384 [3.0.0]: https://github.com/swup/swup/releases/tag/3.0.0
385 [2.0.19]: https://github.com/swup/swup/releases/tag/2.0.19
386 [2.0.18]: https://github.com/swup/swup/releases/tag/2.0.18
387 [2.0.17]: https://github.com/swup/swup/releases/tag/2.0.17
388 [2.0.16]: https://github.com/swup/swup/releases/tag/2.0.16
389 [2.0.15]: https://github.com/swup/swup/releases/tag/2.0.15
390 [2.0.14]: https://github.com/swup/swup/releases/tag/2.0.14
391 [2.0.13]: https://github.com/swup/swup/releases/tag/2.0.13
392 [2.0.12]: https://github.com/swup/swup/releases/tag/2.0.12
393 [2.0.11]: https://github.com/swup/swup/releases/tag/2.0.11
394 [2.0.10]: https://github.com/swup/swup/releases/tag/2.0.10
395 [2.0.9]: https://github.com/swup/swup/releases/tag/2.0.9