Skip to content

Commit

Permalink
UI-943: Add documentation for the getFormData() method
Browse files Browse the repository at this point in the history
  • Loading branch information
joristirado committed Feb 9, 2015
1 parent 6b93874 commit 6b71724
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docs/monster/ui.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ The `monster.ui` object contains different methods and objects used to easily re
* [protectField()][protect_field]
* [validate()][validate]
* [wysiwyg()][wysiwyg]
* [getFormData()][getFormData]

### Objects
* [prettyCheck][pretty_check]
Expand All @@ -23,4 +24,5 @@ The `monster.ui` object contains different methods and objects used to easily re
[dialog]: ui/dialog().md
[protect_field]: ui/protectField().md
[validate]: ui/validate().md
[wysiwyg]: ui/wysiwyg().md
[wysiwyg]: ui/wysiwyg().md
[getFormData]: ui/getFormData().md
21 changes: 21 additions & 0 deletions docs/monster/ui/getFormData().md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# [monster][monster].[ui][ui].getFormData()

* [Syntax](#syntax)
* [Parameters](#parameters)
* [Description](#description)

### Syntax
```javascript
monster.ui.getFormData(rootNode[, delimiter, skipEmpty, nodeCallback, useIdIfEmptyName]);
```

### Parameters
The parameters are the same than the [form2js][form2js] function.

### Description
This method is a wrapper of the form2js function. Its goal is to clean the object returned by form2js of all empty keys when the form passed as a parameter contains inputs without a `name` parameter.

[monster]: ../../monster.md
[ui]: ../ui.md

[form2js]: https://github.com/maxatwork/form2js#form2js

0 comments on commit 6b71724

Please sign in to comment.