Closed Bug 1350223 Opened 9 years ago Closed 9 years ago

alias for all images path in webpack.config

Categories

(DevTools :: Netmonitor, enhancement, P1)

enhancement

Tracking

(firefox55 fixed)

RESOLVED FIXED
Firefox 55
Iteration:
55.3 - Apr 17
Tracking Status
firefox55 --- fixed

People

(Reporter: gasolin, Assigned: rickychien)

References

Details

(Whiteboard: [netmonitor])

Attachments

(1 file)

to Require correct png, svg in css
Depends on: 1350217
Flags: qe-verify?
Priority: -- → P2
Whiteboard: [netmonitor]
Flags: qe-verify? → qe-verify-
Assignee: nobody → rchien
Status: NEW → ASSIGNED
Iteration: --- → 55.2 - Apr 3
Priority: P2 → P1
Finally I figured out that webpack NormalModuleReplacementPlugin is a cool solution for dealing with chrome:// resource:// protocol so it's very likely to the way of resolve.alias. Right now, I can see all assets (svg, png) in css files are bundled properly. STR to verify all images are resolved: 1. yarn start and see webpack log and images are bundles without throwing any error.
Blocks: 1352699
Just wanted to review this but, I am unable to load Netmonitor in Launchpad due to the following errors: Console Service ERROR [JavaScript Error: "TypeError: LocalizationHelper is not a constructor" {file: "http://localhost:8000/assets/build/netmonitor.js" line: 100718}] [JavaScript Error: "TypeError: LocalizationHelper is not a constructor" {file: "http://localhost:8000/assets/build/netmonitor.js" line: 100718}] L10N was disabled? https://github.com/devtools-html/devtools-core/commit/ba74d5ab990affdae5ee39b573239d83154e17f0 Also there is new Stack Trace side-panel (bug 1350234): ERROR in ./src/components/stack-trace-panel.js Module not found: Error: Cannot resolve module 'devtools/client/shared/components/stack-trace' in C:\src\mozilla.org\mozilla-central\devtools\client\netmonitor\src\components@ ./src/components/stack-trace-panel.js 16:33-89 Do we have to move this to devtools-core/devtools-modules package? Honza
Flags: needinfo?(rchien)
(In reply to Jan Honza Odvarko [:Honza] from comment #4) > Just wanted to review this but, I am unable to load Netmonitor in Launchpad > due to the following errors: > > Console Service ERROR [JavaScript Error: "TypeError: LocalizationHelper is > not a constructor" {file: "http://localhost:8000/assets/build/netmonitor.js" > line: 100718}] [JavaScript Error: "TypeError: LocalizationHelper is not a > constructor" {file: "http://localhost:8000/assets/build/netmonitor.js" line: > 100718}] > > L10N was disabled? > https://github.com/devtools-html/devtools-core/commit/ > ba74d5ab990affdae5ee39b573239d83154e17f0 Yes, you can re-enable it but it's irrelevant to this bug. > Also there is new Stack Trace side-panel (bug 1350234): > > ERROR in ./src/components/stack-trace-panel.js > Module not found: Error: Cannot resolve module > 'devtools/client/shared/components/stack-trace' in > C:\src\mozilla.org\mozilla- > central\devtools\client\netmonitor\src\components@ > ./src/components/stack-trace-panel.js 16:33-89 > > Do we have to move this to devtools-core/devtools-modules package? Yep, new PR for devtools-core will be opened soon. See comment 2, this bug targets on "alias for all images path in webpack.config" so you can verify that by doing STR in comment 2 and see assets of webpack log are resolved properly. Bug 1352699 is doing the thing that make netmonitor run on browser (like our experiment repo), so only thing we should verify here is that: Get rid of all webpack module resolve errors after removing //require("src/assets/style/netmonitor.css") in index.js.
Flags: needinfo?(rchien)
Iteration: 55.2 - Apr 3 → 55.3 - Apr 17
Updated patch for fixing stace-trace component errors and open PR for exporting StaceTrace property in devtools-module (https://github.com/devtools-html/devtools-core/pull/310). Honza, you can check my patch again and remember to update devtools-core once https://github.com/devtools-html/devtools-core/pull/310 is landed.
Note that splitbox has been moved from devtools-modules to devtools-splitter https://github.com/devtools-html/devtools-core/pull/308/files. Folow-up update will be fixed in bug 1352699.
The easiest way to verify images asset is try to make webpack throw error. We can simply remove `"devtools/client/framework/devtools": "devtools-modules"` in webpack.config.js and then see images chunk are bundled properly.
Flags: needinfo?(odvarko)
Comment on attachment 8853354 [details] Bug 1350223 - alias for all images path in webpack.config https://reviewboard.mozilla.org/r/125472/#review129496 I don't see any troubles on my machine. Thanks! Honza
Attachment #8853354 - Flags: review?(odvarko) → review+
Just removing NI Honza
Flags: needinfo?(odvarko)
Pushed by rchien@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/9cfa45d5cf0c alias for all images path in webpack.config r=Honza
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 55
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: