Forum Replies Created

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • in reply to: Can't get the CSS files built #107998
    Ali Khallad
    Participant

    After digging a bit, I understood that the other rules of module.export does not search by directory or anything, but rather handles files imported from the main js that is in the entry point I suppose.

    How can I make it instead get a whole directory for example block/css/block.css block/css/block.editor.css then build those into the appropriate folder with appropriate names

    Now when I run it on ‘blocks/index.js’ it has the import ‘document’ inside it which make the rest of code handles css imported to this js file, when I change to my js file that has no import it run without an issue but my css folder is not generated.

    in reply to: Can't get the CSS files built #107997
    Ali Khallad
    Participant

    Not there, all seem to be correct, I tried to copy exact webpack file from gutenberg-course and copied blocks folder, then it generated correctly on my plugin, but after one change to module.exports.entry, I changed the names for JS file and npm run dev again and it generated js but not css, this is a bit confusing.

    in reply to: Can't get the CSS files built #107982
    Ali Khallad
    Participant

    It does work when using with the demo plugin although it produce some errors. However, when trying on my own plugin it doesn’t, I shared the setup above.

Viewing 3 posts - 1 through 3 (of 3 total)