Skip to content

stateful fetch client #435

@pi0

Description

@pi0

Describe the feature

ofetch/$fetch same as native fetch is stateless by-design. This has safety advantages when ofetch is deeply integrated into tools such as Nitro and Nuxt and prevents global side effects and potential header leaks.

However, there are also good use cases of having stateful fetch instances:

I think $fetch.withState() could be useful.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions