[network] Allow NetworkRequetNodes to be gc'ed when the log is cleared

The network panel currently associates each NetworkRequest with it's
UI data grid node via a WeakMap. But since the ResourceTreeModel never
frees up NetworkRequests, we keep every <tr> of the Network panel alive
indefinitely.

This CL fixes at least the DOM element leak: When the view is reset,
we also reset the WeakMap. While we keep the NetworkRequests around
for now, at least we no longer keep detached DOM nodes around
indefinitely.

Drive-by: Make the module global a class member.

[email protected]

Bug: 390559089
Change-Id: I014ec2c56bab20f6c48c85cb205476860ea5c829
Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6759714
Auto-Submit: Simon Zünd <[email protected]>
Reviewed-by: Philip Pfaffe <[email protected]>
Commit-Queue: Simon Zünd <[email protected]>
1 file changed
tree: 320220c72139c2c88a75f3df5eaca30654496e12
  1. .github/
  2. .vscode/
  3. build_overrides/
  4. config/
  5. docs/
  6. extension-api/
  7. extensions/
  8. front_end/
  9. inspector_overlay/
  10. node_modules/
  11. scripts/
  12. test/
  13. third_party/
  14. v8/
  15. .clang-format
  16. .clang-format-ignore
  17. .editorconfig
  18. .git-blame-ignore-revs
  19. .gitallowed
  20. .gitattributes
  21. .gitignore
  22. .gitmodules
  23. .gn
  24. .mailmap
  25. .npmignore
  26. .npmrc
  27. .style.yapf
  28. .stylelintignore
  29. .stylelintrc.json
  30. AUTHORS
  31. BUILD.gn
  32. codereview.settings
  33. CONTRIBUTING.md
  34. DEPS
  35. DIR_METADATA
  36. eslint.config.mjs
  37. favicon.ico
  38. LICENSE
  39. OWNERS
  40. package-lock.json
  41. package.json
  42. PRESUBMIT.py
  43. README.md
  44. WATCHLISTS
README.md

Chrome DevTools frontend

npm package

The client-side of the Chrome DevTools, including all TypeScript & CSS to run the DevTools webapp.

Source code and documentation

The frontend is available on chromium.googlesource.com. Check out the Chromium DevTools documentation for instructions to set up, use, and maintain a DevTools front-end checkout, as well as design guidelines, and architectural documentation.

Source mirrors

DevTools frontend repository is mirrored on GitHub.

DevTools frontend is also available on NPM as the chrome-devtools-frontend package. It's not currently available via CJS or ES modules, so consuming this package in other tools may require some effort.

The version number of the npm package (e.g. 1.0.373466) refers to the Chromium commit position of latest frontend git commit. It's incremented with every Chromium commit, however the package is updated roughly daily.

Getting in touch

There are a few options to keep an eye on the latest and greatest of DevTools development: