Coder Social home page Coder Social logo

Bug: requestURL when body is arraybinary or formdata, I try to transform formdata to array put it in body of request, but failed. about obsidian-api HOT 6 CLOSED

ai-chen2050 avatar ai-chen2050 commented on August 28, 2024
Bug: requestURL when body is arraybinary or formdata, I try to transform formdata to array put it in body of request, but failed.

from obsidian-api.

Comments (6)

ai-chen2050 avatar ai-chen2050 commented on August 28, 2024 1

Thx, I fix this problem, just replace body: post_typedArray using body: post_typedArray.buffer.

from obsidian-api.

lishid avatar lishid commented on August 28, 2024

requestUrl does not support FormData. You must supply the full http request body either as a string or as an ArrayBuffer. Unfortunately this does make it quite a bit tedious to work with multipart form data.

from obsidian-api.

maxtimbo avatar maxtimbo commented on August 28, 2024

Is there a possibility of this getting patched to accept multipart form data?

from obsidian-api.

ai-chen2050 avatar ai-chen2050 commented on August 28, 2024

Is there a possibility of this getting patched to accept multipart form data?

You can simulate a multipart form data request, as follows.

  • go to my project and give it a star, thx
  • then click here to watch some details about how to handle using form-data

from obsidian-api.

maxtimbo avatar maxtimbo commented on August 28, 2024

then click here to watch some details about how to handle using form-data

Yep, I've looked over your code a bunch of times. It's the only reference I've been able to find. It has not worked for my use case. See the code and my attempts here

from obsidian-api.

ai-chen2050 avatar ai-chen2050 commented on August 28, 2024

Sorry to hear about that, You can try other ways more. I am working now, so I may check out your code details when I am not busy.

from obsidian-api.

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.