Extract and set form values through the DOM—no frameworks required! https://github.com/TheoryOfNekomata/formxtra
Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

12345678910111213141516171819202122
  1. # get-form-values
  2. Get the value of a form using `HTMLFormElement.elements`.
  3. ## Usage
  4. ```typescript
  5. import getFormValues from '@theoryofnekomata/get-form-values';
  6. const form = document.getElementById('form')
  7. // optional, but just in case there are multiple submit buttons in the form,
  8. // individual submitters can be considered
  9. const submitter = form.querySelector('[type="submit"]')
  10. const values = getFormValues(form, submitter)
  11. ```
  12. ## Tests
  13. The library has been tested on JSDOM through Jest, and the real DOM using
  14. Cypress.