Categorize, sort, and filter a responsive grid of items
Full Changelog: https://github.com/Vestride/Shuffle/compare/v6.1.0...v6.1.1
package.json
now contains sideEffects: false
to improve dead code removal and tree shaking.
package.json
now contains an export-map to assist bundlers in choosing the correct file.index.d.ts
(in #402) to be more accurate with the real code.Full Changelog: https://github.com/Vestride/Shuffle/compare/v6.0.0...v6.1.0
matches-selector
package and use the native matches
(see browser support).delimeter
option (the misspelled one). Use the delimiter
option instead.ResizeObserver
(#321). Browser support for it is very good, but if you want to support a browser that doesn't have it, you can manually add a window resize event and call update()
within the event callback.
throttleit
dependencythrottle
option.throttleTime
option.update()
.
-shuffle.update(true);
+shuffle.update({ recalculateSizes: false });
element.getAttribute('data-groups')
. Now, it uses element.dataset.groups
. dataset
is very well supported now.force
option to update
method to force shuffle to update even if it's disabled (#321).
shuffle.update({ force: true });
.browserslistrc
.sortedItems
property which is the shuffle items in sorted order. Only visible items are in this array.Add isRTL
option thanks to @AmirHosseinKarimi
The TypeScript definitions were missing on
, once
, emit
, and off
because the definitions file did not have extends TinyEmitter
. These methods now work correctly and contain type information for the data
object in the event callback.
Moved to jest for testing #278
enable
, update
, and getSize
.Css
export on Shuffle.ShuffleItem.Css
.Shuffle.ALL_ITEMS
and Shuffle.FILTER_ATTRIBUTE_KEY
not being overridable..sort()
method's options: SortOptions
..filter()
's function signature.ShuffleItem.Css
.ts
file.tsc
on test file during tests.Element
to HTMLElement
.Shuffle.ShuffleOptions
is now exported top-level.
import Shuffle, { ShuffleOptions, SortOptions } from 'shufflejs';
Full changes: https://github.com/Vestride/Shuffle/compare/v5.2.1...v5.2.2
Change typings to use default export #214
-export = Shuffle;
+export default Shuffle;
Upgraded dev dependencies to their latest versions:
Removed @odopod/eslint
as I no longer have write access to Odopod's repos.
getComputedStyle
has been moved to a lazily-evaluated function instead of happening when the file is imported.Fix misspelled delimiter
option. Both "delimiter" (correct) and "delimeter" (incorrect) will continue to work for v5. #215