Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

formSerializer indexes:false not working as expected #6396

Open
maxwelladapoe opened this issue May 16, 2024 · 3 comments
Open

formSerializer indexes:false not working as expected #6396

maxwelladapoe opened this issue May 16, 2024 · 3 comments

Comments

@maxwelladapoe
Copy link

maxwelladapoe commented May 16, 2024

Describe the issue

I am trying out the formSerializer to remove the indexes when setting formdata following this approach. However it doesnt seem to remove the indexes. Am i doing something wrong?

Example Code

axios.put(url, data, { headers: { "Content-Type": "multipart/form-data", }, formSerializer: { indexes: false, }, });

Expected behavior

To take out the index
image
despite adding this it seems it still keeps the index

Axios Version

1.4.0

Adapter Version

No response

Browser

No response

Browser Version

No response

Node.js Version

No response

OS

No response

Additional Library Versions

No response

Additional context/Screenshots

No response

@throrin19
Copy link

Same problem with paramSerializer

@mattfordham
Copy link

I'm experiencing the same issue.

@arsenasatryan
Copy link

arsenasatryan commented Dec 27, 2024

setting {indexes: null} should solve the issue, I have checked the code and it is handled. Here is the snippet from the readme

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants