`useAsyncData`: dedupe: false
Open
Nobody has claimed this yet.
🍰 p2-nice-to-have
- Dominant language
- TypeScript
- Stars
- 60.9k
- Forks
- 5.8k
- Avg merge
- 7h 8m
- Merged PRs (30d)
- 162
Description
Describe the feature
Make it possible to disable deduplication of the requests. Useful for a throttled search for example.
const search = ref('')
const throttledSearch = useThrottle(search, 500)
const { data } = useFetch('/api/search', {
query: computed(() => ({ text: throttledSearch.value })),
immediate: !!throttledSearch.value,
dedupe: false, // Here
})
All requests would be made and update data to update the search results as the user types.
Additional information
- Would you be willing to help implement this feature?
- Could this feature be implemented as a module?
Final checks
- Read the contribution guide.
- Check existing discussions and issues.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the useAsyncData and useFetch implementations and inspect how their current request deduplication works. Check the related tests, then verify that setting dedupe: false allows every request to proceed and updates data with the search results as values change.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- nuxt, typescript
- Domain
- api
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100