Package Exports
- parse-form
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (parse-form) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Parse-Form
Utility convert a form to json in the way that a browser might. Supports files, and every type of native input.
Installation
Npm
npm install parse-form
Example
<form id="my-form">
<input type="text" name="a[b][c]" value="hello world"/>
<input type="file" name="myFyle" value=.../>
<button type="submit">Submit</button>
</form>
var parse = require("parse-form");
var form = document.getElementById("my-form");
parse(form);
/**
* {
* body: { a: { b: { c: "hello world" } } },
* files: { myFile: [...] }
* }
*/
Contributions
- Use gulp to run tests.
Please feel free to create a PR!