SkillAgentSearch skills...

Serialize

serialize a form to urlencoded string.

Install / Use

/learn @yields/Serialize
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

serialize

serialize forms.

Installation

Install with component(1):

$ component install yields/serialize

Example

<input type='text' name='foo' value='baz'>
<input type='text' name='baz' value='foo'>
<select name='select'>
  <option value='1'></option>
</select>

<script>
  var el = document.forms[0];
  assert('foo=baz&baz=foo&select=1' == serialize(el));

  serialize.object(el);
  // => { foo: "baz", baz: "foo", select: "1" }
</script>

License

MIT

Related Skills

View on GitHub
GitHub Stars27
CategoryDevelopment
Updated2y ago
Forks2

Languages

JavaScript

Security Score

60/100

Audited on Aug 22, 2023

No findings