Hacker News new | ask | show | jobs
by dphnx 1355 days ago
`document.all` can be used in this way:

  <div id="foo"></div>
  <script>
    const { foo } = document.all
    // do something with foo
  </script>
Don't use it though, it's deprecated as well[1].

[1]: https://developer.mozilla.org/en-US/docs/Web/API/Document/al...