Skip to content

Webpack process only picks up some of the css files in a theme #9

@handrews

Description

@handrews

As filed by @Relequestual as cloudflare/doca#40

When creating a theme with multiple css files in the styles folder, not all of them are always pick up and included.

Noted at cloudflare/doca#39 (comment)

I think I found the cause of this problem!
I had installed bootstrap, but removed the font files.
The CSS loader had a problem when it couldn't find the fonts, and died, without saying a word.
I only noticed this when I restarted the server in development mode and saw it in the console while it was trying to reload modules.
Added the fonts back, no problem.

I still came across a load order issue, but because they are loaded in alphabetical order (it seems), that's easy to fix.

Added another CSS file. Still have the problem where it's not picked up at...
require.context('doca-bootstrap-theme/styles', true, /\.css$/gi);
main.js

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions