{"id":15048118,"url":"https://github.com/github/form-data-entries","last_synced_at":"2025-10-04T07:31:12.784Z","repository":{"id":57240267,"uuid":"123220612","full_name":"github/form-data-entries","owner":"github","description":"FormData.entries ponyfill","archived":true,"fork":false,"pushed_at":"2020-08-03T16:11:51.000Z","size":19,"stargazers_count":38,"open_issues_count":0,"forks_count":10,"subscribers_count":131,"default_branch":"main","last_synced_at":"2024-12-13T22:07:55.977Z","etag":null,"topics":["formdata","ponyfill"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/github.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-02-28T02:58:16.000Z","updated_at":"2024-11-11T09:05:15.000Z","dependencies_parsed_at":"2022-09-05T08:20:49.161Z","dependency_job_id":null,"html_url":"https://github.com/github/form-data-entries","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github%2Fform-data-entries","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github%2Fform-data-entries/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github%2Fform-data-entries/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github%2Fform-data-entries/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/github","download_url":"https://codeload.github.com/github/form-data-entries/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235227462,"owners_count":18956137,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["formdata","ponyfill"],"created_at":"2024-09-24T21:08:23.240Z","updated_at":"2025-10-04T07:31:07.507Z","avatar_url":"https://github.com/github.png","language":"JavaScript","readme":"# FormData.entries ponyfill\n\nThis [ponyfill](https://ponyfill.com/) implements the `FormData` serialization algorithm. It aims to be compatible with calling the native `new FormData(form).entries()`. [jQuery's `serializeArray`](https://api.jquery.com/serializeArray/) is another implementation example.\n\n## Usage\n\n```js\nimport formDataEntries from 'form-data-entries'\n\nfor (const [name, value] of formDataEntries(myForm)) {\n  console.log(`${name}=${value}`)\n}\n```\n\n## Why ponyfill?\n\nThis package implements `FormData.entries` as a module [ponyfill](https://ponyfill.com/) rather than a polyfill. `FormData.entries` was a later addition to the `FormData` specification. Therefore browsers may support `FormData` but not the `entries` method. It would be dangerous to attempt to fill just this additional `entries` method in browsers that have partial support. This module only implements `entries` as a standalone function which will even work in browsers with no `FormData` support.\n\nHowever, once `FormData.entries` is widely supported this package should be considered obsolete.\n\n## Undefined Behavior\n\nThis module makes a best effort to match the behavior of native `FormData.entries`. It should be possible in the future to replace calls to `formDataEntries(form)` with `new FormData(form).entries()`. However, there are some cases where this module can not fully match the native behavior.\n\n- If the form contains any `\u003cinput type=file\u003e` elements, the behavior is considered undefined and should not be relied upon.\n- In Safari when `FormData` is constructed on the submit event, it will include the [`submitter`](https://html.spec.whatwg.org/#constructing-form-data-set) value. This behavior does not exist in other browsers, and is not and can not be implemented in the ponyfill since [the `submitter` element is not exposed](https://github.com/whatwg/html/issues/3195).\n\n## Test Suite\n\n* [Run test suite against ponyfill implementation](https://github.github.com/form-data-entries/test/test-ponyfill.html)\n* [Run test suite against browser's native implementation](https://github.github.com/form-data-entries/test/test-native.html)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgithub%2Fform-data-entries","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgithub%2Fform-data-entries","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgithub%2Fform-data-entries/lists"}