You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Like the URLSearchParams allow the FormData constructor able to accept a iterable array or object
instead of having to manually append everything
Current way of solving things:
vardata=['foo','bar']vardata={foo: 'bar'}varfd=newFormData()for(let[key,val]ofnewURLSearchParams(data)){fd.append(key,val)}// or one-liner newURLSearchParams(data).forEach(args=>fd.append(...args))
Like the URLSearchParams allow the FormData constructor able to accept a iterable array or object
instead of having to manually append everything
Current way of solving things:
Suggested way
The text was updated successfully, but these errors were encountered: