Closed devpaul closed 6 years ago
The requiring of the m.css
file is done by the css-modules
build and via a replacement plugin also so I think that adding an extra require
would cause it to load it twice. Or are you saying that that process fails for just this file on your machine?
The require statement is prefixed to the start of *.m.css.js
files as part of a working dojo build process. The code snippets I provided are for slider.m.css.js
as reported by WebPack in it's debug output. All of my *.m.css.js
that are included in the build are missing the require line and as a result you'll see that there's no dependency anywhere for widget-core's slider.m.css
(or other widget-core css).
If you download the zip and look at the profiles in WebPack analyzer it's a little easier to read.
Missing css dependency:
Expected:
@devpaul @tomdye has this been addressed?
@devpaul Can you confirm if this is still an issue using cli-build-app
and cli-build-widget
? If so can you move the issue to one or both of them?
I'll check and update the ticket.
Closing this until we hear further information, this has not been reproducible for any one else at the moment. If this is still an issue on cli-build-app
or cli-build-widget
please create issues against the repositories.
Bug
.m.css
files from @dojo/widgets are not being included in a built project. I've tracked down the issue a bit and found that the build process should be including require statements on the top of.m.css.js
files. I've attached a zip of threeprofile.json
files produced during a debugged build.profile-expected.json
is of a working build and the other two are from my Windows and Mac machines; both exhibit the same issue.Package Version: ~0.1.0 Node version: 6.11.3 npm version: 4.6.1
Code
built using
./node_modules/.bin/dojo build --debug --element=src/createPlayerElement.ts
and used WebPack analyzer to view the profile.json.Expected behavior:
This is the expected output of
./~/@dojo/widgets/slider/styles/slider.m.css.js
. A require statement is added to the top of the file, which informs webpack to include thecss
file as a dependency.Actual behavior:
The require statement is not added.
profiles.zip