You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When attempting to access function toggleAttribute after .querySelector, an error is displayed:
container.toggleAttribute('disabled');
^
TypeError: container.toggleAttribute is not a function
at file:///D:/Projects/happ-dom-repro1/index.js:9:11
at ModuleJob.run (node:internal/modules/esm/module_job:193:25)
at async Promise.all (index 0)
at async ESMLoader.import (node:internal/modules/esm/loader:530:24)
at async loadESM (node:internal/process/esm_loader:91:5)
at async handleMainPromise (node:internal/modules/run_main:65:12)
Node.js v18.12.0
Describe the bug
When attempting to access function
toggleAttribute
after.querySelector
, an error is displayed:According to MDN, this function should be supported:
https://developer.mozilla.org/en-US/docs/Web/API/Element/toggleAttribute
To Reproduce
Run this code with
node index.js
after basing it off the basic example:Expected behavior
Attributes should be toggle on/off as expected of the spec from MDN.
Device:
The text was updated successfully, but these errors were encountered: