GithubHelp home page GithubHelp logo

Not work with FormData about redaxios HOT 5 CLOSED

developit avatar developit commented on June 19, 2024 3
Not work with FormData

from redaxios.

Comments (5)

developit avatar developit commented on June 19, 2024 3

Fix published in version 0.3.0.

from redaxios.

fabricionaweb avatar fabricionaweb commented on June 19, 2024 1

@crissto I guess we can just check !(data instanceof FormData)
But not sure if that has side-effects... hope @developit knows more than me about it :D

from redaxios.

developit avatar developit commented on June 19, 2024

Good catch. Happy to accept a PR, this will likely require inspecting the constructor.

from redaxios.

crissto avatar crissto commented on June 19, 2024

Hi!
would the solution to this be, check if data is FormData and set a different Content-Type? If it's that I can fix it and send a PR

from redaxios.

developit avatar developit commented on June 19, 2024

@fabricionaweb yup, that's likely going to be the smallest check.

Another option would be checking if (typeof data.append=='function'){}, but the size win likely isn't worth the false positive chance.

from redaxios.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.