@themythicalcoder/json-to-formdata
v1.0.0
Published
This package allows you to convert the json file to formdata
Downloads
2
Maintainers
Readme
Json-To-Form-Converter
This package allows you to convert the Jsondata to Formdata.
Docs!
Import the module and call the convertJSONToFormData function with the parameters.
Value : Json Data which needs to be converted.
Sample Code!
const convertfm = require("json-to-formdata")
const jsonData = {
key1: 'value1',
key2: 'value2',
key3: 'value3',
};
console.log(convertfm(jsonData));
Output
C:\Users\Desktop\Npm\Conversion>node script.js
FormData {
[Symbol(state)]: [
{ name: 'key1', value: 'value1' },
{ name: 'key2', value: 'value2' },
{ name: 'key3', value: 'value3' }
]
}