Skip to content

useFetch post call inserts quotes when passed a string #360

Open
@nibblesnbits

Description

@nibblesnbits

Describe the bug
useFetch post call inserts quotes when passed a string.

⚠️ Make a Codesandbox ⚠️
Please click this to easily reproduce the bug.

To Reproduce
Steps to reproduce the behavior:

  1. Go to https://codesandbox.io/s/strange-wave-onbnw?file=/src/App.js
  2. Open devtools and observe network call to `/test'
  3. View request payload
  4. See that "test" is exctly that. The word "test" wrapped in quotes.

Expected behavior
I expect a string to be passed into the body of the request as a string, not wrapped in quotes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions