Remove SourceMapService in favor of SourceMapLoader
Categories
(DevTools :: Debugger, task)
Tracking
(firefox110 fixed)
Tracking | Status | |
---|---|---|
firefox110 | --- | fixed |
People
(Reporter: ochameau, Assigned: ochameau)
References
(Blocks 1 open bug)
Details
Attachments
(6 files)
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review |
Today there is an intermediate layer called "SourceMapService", built from the toolbox class:
https://searchfox.org/mozilla-central/rev/83b86005c6913c2062419efb8aabdf2e683aa47f/devtools/client/framework/toolbox.js#1380-1454
This uses JS Proxy to hack the SourceMapLoader layer. Instead these hacks should be distributed into either SourceMapLoader or the callsites.
Also, we could simplify the SourceMapLoader by:
- using the regular DevTools Loader to load it
- store the various worker module URLs in the "index.js" files instead of requiring the callsites to know the worker url.
- rename sourceMapService to sourceMapLoader (this will clarify a bit more the difference between SourceMapLoader and SourceMapURLService).
Assignee | ||
Comment 1•2 years ago
|
||
This allows using a regular worker and no longer have to be related to any particular document.
Updated•2 years ago
|
Assignee | ||
Comment 2•2 years ago
|
||
This simplify the frontend code/callsites by not having to know where the worker file is.
Assignee | ||
Comment 3•2 years ago
|
||
Now that source-map-loader uses ChromeLoader, it doesn't need to be loaded
via the Browser Loader. It was mostly used to be able to access window.Worker symbol.
It was also exposing fetch
global symbol. DevTools Loader wasn't exposing it.
I fixed that as this symbol is available in JSM/ESM.
Assignee | ||
Comment 4•2 years ago
|
||
This will help get rid of the proxy entirely.
Assignee | ||
Comment 5•2 years ago
|
||
Assignee | ||
Comment 6•2 years ago
|
||
Comment 8•2 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/b80085248912
https://hg.mozilla.org/mozilla-central/rev/03a9f2939f63
https://hg.mozilla.org/mozilla-central/rev/4d081dac3e31
https://hg.mozilla.org/mozilla-central/rev/8435c181b8b9
https://hg.mozilla.org/mozilla-central/rev/208656a729be
https://hg.mozilla.org/mozilla-central/rev/136a6746e5db
Description
•