Skip to content

A convenient client-side JavaScript function to create a FormData instance from the key-value pairs of an Object instance.

License

Notifications You must be signed in to change notification settings

yqwoe/object-to-formdata

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

object-to-formdata

A convenient client-side JavaScript function to create a FormData instance from the key-value pairs of an Object instance.

const objectToFormData = require('object-to-formdata')


const object = {
  /**
   * key-value pairs
   * values can be primitives or objects
   */
}

const formData = objectToFormData(object)

console.log(formData)

About

A convenient client-side JavaScript function to create a FormData instance from the key-value pairs of an Object instance.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%