ReviewOS

also looking at this

stacks/vite-plugin-routes

chore(deps): update all non-major dependencies

#2
Merged renovate[bot] wants to merge renovate/all-minor-patch into main
2 files +226 -146
9 days ago

ℹ️ Note

This PR body was truncated due to platform limits.

This PR contains the following updates:

PackageChangeAgeConfidence
@pinia/colada (source)^0.15.3 → ^0.21.7ageconfidence
@shikijs/vitepress-twoslash (source)3.4.2 → 3.23.0ageconfidence
@tanstack/vue-query (source)^5.76.0 → ^5.100.9ageconfidence
@types/bun (source)^1.2.14 → ^1.3.13ageconfidence
@types/picomatch (source)^4.0.0 → ^4.0.3ageconfidence
@vitest/coverage-v8 (source)^3.1.3 → ^3.2.4ageconfidence
@vitest/ui (source)^3.1.3 → ^3.2.4ageconfidence
@vue-macros/common (source)3.0.0-beta.12 → 3.1.2ageconfidence
@vue/language-core (source)^2.2.10 → ^2.2.12ageconfidence
@vue/test-utils^2.4.6 → ^2.4.10ageconfidence
ast-walker-scope^0.8.1 → ^0.9.0ageconfidence
bun-plugin-dtsx (source)^0.9.4 → ^0.9.17ageconfidence
chalk^5.4.1 → ^5.6.2ageconfidence
execa^9.5.3 → ^9.6.1ageconfidence
firebase (source, changelog)^11.7.3 → ^11.10.0ageconfidence
happy-dom^20.8.9 → ^20.9.0ageconfidence
lint-staged^16.0.0 → ^16.4.0ageconfidence
local-pkg^1.1.1 → ^1.1.2ageconfidence
magic-string^0.30.17 → ^0.30.21ageconfidence
mlly^1.7.4 → ^1.8.2ageconfidence
nodemon (source)^3.1.10 → ^3.1.14ageconfidence
picomatch^4.0.2 → ^4.0.4ageconfidence
pinia (source)^3.0.2 → ^3.0.4ageconfidence
pnpm (source)10.11.0 → 10.33.2ageconfidence
prettier (source)^3.5.3 → ^3.8.3ageconfidence
rimraf^6.0.1 → ^6.1.3ageconfidence
semver^7.7.2 → ^7.7.4ageconfidence
tsdown (source)^0.11.11 → ^0.21.10ageconfidence
typescript (source)^5.8.3 → ^5.9.3ageconfidence
unplugin (source)^2.3.4 → ^2.3.11ageconfidence
unplugin-auto-import^19.2.0 → ^19.3.0ageconfidence
unplugin-utils^0.2.4 → ^0.3.1ageconfidence
vite (source)^6.3.5 → ^6.4.2ageconfidence
vite-plugin-vue-devtools (source)^7.7.6 → ^7.7.9ageconfidence
vitepress (source)^1.6.3 → ^1.6.4ageconfidence
vitepress-plugin-llms^1.2.0 → ^1.12.2ageconfidence
vitest (source)^3.1.3 → ^3.2.4ageconfidence
vue (source)^3.5.14 → ^3.5.33ageconfidence
vue-router (source)^4.5.1 → ^4.6.4ageconfidence
vue-tsc (source)^2.2.10 → ^2.2.12ageconfidence
vuefire^3.2.1 → ^3.2.3ageconfidence
yaml (source)^2.8.0 → ^2.8.4ageconfidence

Release Notes

posva/pinia-colada (@​pinia/colada)

v0.21.7

Compare Source

Bug Fixes
  • infinite: detach $onAction listener to survive component unmount (c756e3a), closes #​525

v0.21.6

Compare Source

Bug Fixes
Performance Improvements

v0.21.5

Compare Source

Bug Fixes
  • ssr: prevent memory leak (#​514) (9fd9baa)
  • types: restore UseQueryOptions variance for placeholderData callback (ef4a006)
Features
Deprecations
  • The two-parameter form of useQuery(setup, () => params) and useQueryState(setup, () => params) is deprecated. Use a single function parameter instead:

    - useQuery(useContactList, () => ({ search: search.value }))
    + useQuery(() => useContactList({ search: search.value }))

    A codemod is available to automate this migration. Commit your changes first, then run:

    pnpm --package=@​ast-grep/cli dlx ast-grep scan -r node_modules/@​pinia/colada/codemods/rules/migration-0-21-to-1-0.yaml -i src

    See Migration Codemods for details.

v0.21.4

Compare Source

Features

v0.21.3

Compare Source

Bug Fixes
  • infinite-query: compute hasNextPage correctly on cache hit (#​480) (895914a)
  • skip refetchOnWindowFocus and refetchOnReconnect for inactive defined queries (1d7f9d2), closes #​485

v0.21.2

Compare Source

Bug Fixes

v0.21.1

Compare Source

Bug Fixes
Features

v0.21.0

Compare Source

Features
  • expose internal utility types (bb3a7d0)
BREAKING CHANGES

v0.20.0

Compare Source

This release completely changed how useInfiniteQuery() works, the parameters and returned values:

  • The merge option has been removed and data contains an object with pages and pageParams arrays that can be flattened.
  • initialPage has now been replaced with initialPageParam
  • loadMore has been renamed loadNextPage
  • getNextPageParam is now a required option
  • Invalidating now works just as with regular queries, which means that you probably want to set stale value higher (or disable it) to avoid refetching multiple pages when an infinite query is invalidated. Also, you might want to set refetchOn* options to false.
  • It's now possible to have bi-directional navigation
  • There is now hasNextPage and hasPreviousPage

Any feedback on the feature and improvements is welcome!

Here is a complete example of what it looks in action:

<script setup lang="ts">
import { useInfiniteQuery } from '@&#8203;pinia/colada'
import { onWatcherCleanup, useTemplateRef, watch } from 'vue'

const {
  state: factsPages,
  loadNextPage,
  asyncStatus,
  isDelaying,
  hasNextPage,
} = useInfiniteQuery({
  key: ['feed'],
  query: async ({ pageParam }) => factsApi.get<CatFacts>({ query: { page: pageParam, limit: 10 } }),
  initialPageParam: 1,
  getNextPageParam(lastPage) {
    return lastPage.next_page_url
  }
  // plugins
  retry: 0,
  delay: 0,
})

// we only need an array
const facts = computed(() => factPages.value.data?.pages.flat())
const loadMoreEl = useTemplateRef('load-more')

watch(loadMoreEl, (el) => {
  if (el) {
    const observer = new IntersectionObserver(
      (entries) => {
        if (entries[0]?.isIntersecting) {
          loadNextPage()
        }
      },
      {
        rootMargin: '300px',
        threshold: [0],
      },
    )
    observer.observe(el)
    onWatcherCleanup(() => {
      observer.disconnect()
    })
  }
})
</script>

<template>
  <div>
    <button :disabled="asyncStatus === 'loading' || isDelaying" @&#8203;click="loadMore()">
      Load more (or scroll down)
    </button>
    <template v-if="facts?.length">
      <p>We have loaded {{ facts.length }} facts</p>
      <details>
        <summary>Show raw</summary>
        <pre>{{ facts }}</pre>
      </details>

      <blockquote v-for="fact in facts">
        {{ fact }}
      </blockquote>

      <p v-if="hasNextPage" ref="load-more">Loading more...</p>
    </template>
  </div>
</template>
Bug Fixes
Features

0.19.1 (2025-12-17)

Features

v0.19.1

Compare Source

Features

v0.19.0

Compare Source

Bug Fixes
  • use global options for mutations (0f3a56c)
Features
  • types: usemutationoptionswithdefaults (67ea7a6)
BREAKING CHANGES
  • Mutations id are now just an incremented number that starts at 1. There is no longer a $n appended to keys for mutations and mutations without a key do not have an artificial key anymore. This is because initially the cache map was a more complex type but with it being a simple Map, there is no point in complexifying the keys. As a result the mutationCache.get() now takes the id of the mutation while getEntries() work the same. The exact filter has also been removed as mutations are, by nature, meant to be called multiple times.

0.18.1 (2025-12-11)

Bug Fixes
Features

0.18.0 (2025-12-02)

⚠ BREAKING CHANGES
  • While technically a fix, this is a breaking change if you were relying on an external signal that aborts within the query. It used to not set the state by just being an AbortError DomException and now it will become an error. This behavior is more correct as we don't want to ignore aborted signals that are external. Each fetch creates an AbortController and passes the signal to query which is aborted (without a reason) if any other method of the store fetches again. This is done to avoid using an outdated request.
Bug Fixes
  • query: preserve any external AbortError (0cdf7b9)

0.17.9 (2025-11-24)

Features
  • export mutation cache (892049f)
  • expose mutation cache (7f6316f)
  • warn wrong useMutationcache usage (211911d)

0.17.8 (2025-11-07)

Bug Fixes
  • allow passing extra options to defineQueryOptions (597597f)
  • types: allow interfaces in keys (19ab616), closes #​420

0.17.7 (2025-10-30)

Bug Fixes
Performance Improvements

0.17.6 (2025-09-25)

Bug Fixes

0.17.5 (2025-09-11)

Features
  • query: add overloaded for optional define options params (#​386) (1c51923)

0.17.4 (2025-09-09)

Bug Fixes

0.17.3 (2025-09-01)

Features

0.17.2 (2025-08-25)

Features
  • expose internal method to plugins (740e1ce)
Bug Fixes

0.17.1 (2025-06-13)

Bug Fixes

0.17.0 (2025-06-03)

⚠ BREAKING CHANGES
  • replace EntryNodeKey with EntryKey
  • types: The EntryKeyTagged type now has multiple type params and an array is no longer assignable to it. This is necessary to correctly infer the types for TData and TDataInitial and if you were manually using EntryKeyTagged, you will either need to cast arrays to it or use EntryKey instead. In most cases this should not affect you. This makes types stricter and also disallows setting a query data to undefined. If you were doing queryCache.setQueryData(key, undefined), use queryCache.setEntryState instead.
Features
Bug Fixes
  • types: avoid incorrect undefined from tagged keys (9358619)
  • types: make options parameter optional in types (#​224) (20bca79)
Code Refactoring
  • remove deprecated EntryNodeKey (6c7d15b)

0.16.1 (2025-05-22)

Bug Fixes
  • ssr: make when relative to work across timezones (43b4f7d), closes #​293

0.16.0 (2025-05-21)

This is the biggest release to date! Many bug fixes, typed keys, a lighter and faster build!

⚠ BREAKING CHANGES
  • query: queryCache.invalidateQueries() now accepts a second parameter to control whether to refetch or not active queries. It can be set to 'all' to force fetch all queries. This replaces the existing behavior of passing active: null (can be removed now) which wasn't actually working. You shouldn't be negatively affected by this change as it wasn't working previously.
  • The internal cache structure has been refactored to be simpler, faster and smaller. Keys now support deeply nested objects and partially matches them when filtering (e.g. queryCache.getEntries()). To achieve this, the hydrated version of the cache has changed. serializeTreeMap has been removed but serializeQueryCache (which should be preferred) has been kept. EntryNodeKey and TreeMapNode (internals) have been removed. EntryNodeKey was just string | number. toCacheKey has been adapted and now returns a plain string rather than an array. This also fixed queryCache.getEntries(['1']) actually returning entries defined with a numeric key ([1]). The type for key is now stricter to ensure everything works well at the type level, you might notice it doesn't allow undefined as a value (except in objects), this is intended as the serialized version (JSON) transforms it no null, and will not match in the cache if used, if you want an nullish value, use null. The documentation has been updated to reflect this
  • types: If you built a plugin, you will have to rename the type params of generics like UseQueryEntryExtensions from TResult to TData. Otherwise, this change won't affect you.
Features
  • allow deeply nested structured keys (59227a8), closes #​149
  • query: allow dynamic typed keys (0053deb)
  • query: allow for typed query keys (5068a52)
  • queryCache.setQueriesData (4818d3e)
  • types: explicit types for useInfiniteQuery (5eb9e3b)
  • types: stricter keys (02f0269)
Bug Fixes
  • avoid fetch with initialData (d1eb4c2)
  • query: gc entries created through dynamic useQuery in defineQuery (90d5d83)
  • query: invalidate inactive queries too (cf5a790), closes #​287
  • query: restore reactivity after unmounting defineQuery (dc2315a), closes #​290
  • types: make key types stricter (9669605)
Reverts
  • Revert "refactor: use external interface for QueryCache" (d6befc4)
Code Refactoring
  • types: rename TResult into TData (09338a2)

0.15.3 (2025-05-06)

Bug Fixes
  • correctly handle refetchOn* when false (262c090)

0.15.2 (2025-05-03)

Bug Fixes

0.15.1 (2025-04-26)

Bug Fixes

0.15.0 (2025-04-18)

⚠ BREAKING CHANGES
  • mutations: mutations are now created each time they are invoked. This change will only affect users directly creating entries with the mutation store (which should be avoided except in very advanced cases). Given the new structure of mutation entries and the fact that they are recreated for each mutation in order to keep a history of mutations, the new process simplifies things and reduces bundle size. The actions create and ensure in the mutation store are now simpler and take less arguments (many were redundant). Alongside these changes, the mutation store has fixed many subtle bugs.
Features
  • add gcTime option for global mutations (2850167)
  • add mutation id (8c8edd5)
  • hmr: refetch on component change (56aad7a)
  • mutations: simplify the entry creation in the mutation store (a96a8ff)
  • untrack mutation entries (6b65f19)
Bug Fixes
  • an entry with no options is stale (3f59d6c)
  • defineQuery: avoid pausing still active (fe00447), closes #​246
  • mutations: create entries for each individual mutation (3def820)
  • query: avoid deleting children of gced queries (5ec6dcc)
  • setQueryData sets the status and trigger gc if possible (8137fbd)
  • types: allow tuples in keys (f8e8087)
  • types: infer initial data in setEntryState (0a94887)
Reverts
  • Revert "refactor: deprecate onMutate in favor of onBeforeMutate" (02add4a). This change never actually made it, it's here for the trace.

0.14.2 (2025-03-26)

Features
  • allow global mutation hooks (045b057)
  • avoid incompatible line with Vue 2 (0c614db)
Bug Fixes

0.14.1 (2025-03-18)

Bug Fixes
  • types: allow extending global query options (28acdd0)

0.14.0 (2025-03-18)

This version introduces codemods to automate migrations 🎉. Try them out with:

pnpm --package=@&#8203;ast-grep/cli dlx ast-grep scan -r node_modules/@&#8203;pinia/colada/codemods/rules/migration-0-13-to-0-14.yaml -i src

You can also globally install ast-grep and run:

ast-grep scan -r node_modules/@&#8203;pinia/colada/codemods/rules/migration-0-13-to-0-14.yaml -i src

Remember to commit changes before running the codemods.

⚠ BREAKING CHANGES
  • Every global query (useQuery() and defineQuery()) option passed to PiniaColada has been moved to its own option queryOptions:

    app.use(PiniaColada, {
      plugins: [],
    -  gcTime: 20_000,
    +  queryOptions: {
    +    gcTime: 20_000,
    +  },
    })

    You can also use the new codemods to automatically migrate this.

  • types: This changes allows for Pinia Colada global options to auto complete but it also requires you to use pass an options object to app.use(PiniaColada, {}). This is just for typing reasons (it could be a limitation of Vue) but the same old code actually works.

    -app.use(PiniaColada)
    +app.use(PiniaColada, {})
  • Replace serialize with serializeTreeMap

  • Removed reviveTreeMap (not needed)

  • Removed internal createdQueryEntry

Features
  • add codemods for migrations (1a2d552)
  • allow global placeholderData (a98528a), closes #​216
  • allow invalidating all queries no matter their active status (a64f674)
  • allow nullish filters (aadd11d)
Bug Fixes
  • avoid cancels to change the status (138857c), closes #​210
  • avoid unnecessary triggerCache (a3494a0)
  • initialize the infinite query pages (9efb7d4)
  • types: correctly type PiniaColada Vue plugin (f01326f)
  • types: placeholderData does not guarantee data (aed71c1), closes #​217
Performance Improvements
Code Refactoring
  • move global query options to its own option (f5e20f0)
  • remove deprecated functions (8ba4362)

0.13.8 (2025-03-09)

Features
  • add more actions to the mutation cache (a38595c)
  • pass previous placeholderData if present (a576093), closes #​197

0.13.7 (2025-03-04)

Bug Fixes

0.13.6 (2025-02-12)

Features
Bug Fixes
  • apply multiple filters to getEntries (da5b00c)

0.13.5 (2025-02-06)

Features
  • add experimental useInfiniteQuery (0a958e6)
Bug Fixes
  • avoid clearing timeouts early (bf7ef2f)
  • correctly track new define queries when switching pages (f9eeec1)
  • make the cache watchable (cf30e68)
  • trigger updates on untrack (91e497a)

0.13.4 (2025-01-31)

Features

0.13.3 (2025-01-14)

Bug Fixes

0.13.2 (2025-01-03)

Bug Fixes

0.13.1 (2024-12-20)

Bug Fixes
  • do not run disabled defined queries on mount (a85ac9f), closes #​138

0.13.0 (2024-11-26)

⚠ BREAKING CHANGES
  • types: placeholderData no longer allows returning null, only undefined. This won't affect most use cases and enables better type inference.
Features
  • types: remove undefined with initialData and placeholderData (#​114) (6e1863e)

0.12.1 (2024-11-09)

Bug Fixes

0.12.0 (2024-11-06)

⚠ BREAKING CHANGES
  • transformError was never fully implemented so they are being removed and might come back if they is a real-word use case for them
  • If you were using the delayLoadingRef util, use the @pinia/colada-plugin-delay instead.
  • Renaming Error to defaultError allows to differentiate the property from the existing global Error class. Upgrading should be straightforward.
Features
  • add initial delay plugin (42c8760)
  • add track and untrack actions for plugins (8902ba3)
  • allow dynamic values for auto refetches (63d2fd0)
  • allow extending useQuery return (ef06628)
  • expose more types (4447d6d)
  • plugins: pass scope for added variables (a3b666f)
  • work without the plugin (696f88e)
Bug Fixes
  • avoid broken reactivity in defineQuery (4c48abc)
  • dedupe pinia colada (6ace8e8)
  • keep data if signal is aborted (de5cde5)
  • pass onMutate context (618312b), closes #​95
  • remove queryCache from mutation hooks (3f1119a)
  • run create in ssr too (1a6fa4a)
  • ssr: throw on error in query (58b7f69)
  • upgrade to new cache format (03e1683)
Code Refactoring
  • query: remove unused transformError and setup options (de0cb48)
  • remove delayLoadingRef helper in favor of the plugins (4c9b4cb)
  • rename the global Error property in

✂ Note

PR body was truncated to here.


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • Between 12:00 AM and 03:59 AM, only on Monday (* 0-3 * * 1)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Enabled.

♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

2 changed files on the files tab, with 0 review threads.

Sign in to comment on this pull request.