Pull in all child libraries of a library/module/theme with dependencies in yml


Well, I suppose if you want to pull them all in, you can nest them under 1 library definition.

Or, add another library definition that contains all of the resources, so you can still use multiple or the whole shebang if you want to.

Tags: Drupal 8

Similar questions

How do I ensure new dependencies added to the info.yml of an existing enabled module are picked up?
I've added to mymodule.info.yml (where mymodule is my module name). How do I ensure Drupal "sees" these new dependencies? For example, can I clear the cache, drush cr ? Or is there another drush command to run or something else to do? When does Drupal read the info.yml file? When module enabled - yes - but what other times? I would prefer...
Is the MODULE.schema.yml required when you define the MODULE.settings.yml?
Is the MODULE.schema.yml required when you define the MODULE.settings.yml? It seems that it also works when I remove the MODULE.schema.yml file from install/schema.
How to inherit base class dependencies without redefining theme in child class service arguments?
I have a set of services classes that extends the same base class ex: and this base class receives these dependencies: So for each child class ex:(NodeHandler , ParagraphHandler) I need always to inject the parent class dependencies ex: I don't want to re-inject the parent dependencies each time I create a service class that extends it unless I wan...
THEME.libraries.yml having no effect
My THEME.info.yml file reads: and my THEME.libraries.yml reads: From all the guides I've found online, this should mean that navbar.css and scrolling.js get included on all pages that use the theme. But that isn't happening. What have I done wrong here, or what steps do I need to take to figure out why it isn't working? In case it's relevant, the f...
Set weight for JavaScript files loaded via theme.libraries.yml?
Im loading a JavaScript file via my theme's libraries.yml file. How can I change the weight of this file? I need the file to load before the core and module's JavaScript files. If I set header: true then this happens, but I still want to load the file at the bottom of the page.
From my child theme, how can I remove a library loaded by the parent theme?
I have hit an issue which I think is quite unusual or peculiar when settingup a child theme. A commercial parent theme I have bought loads the Slick library like this in its theme.libraries.yml: But I don't want the Slick library to be loaded by the parent theme because I will be installing the Slick module, and will be using Slick Views. I found t...

Also ask

We use cookies to deliver the best possible experience on our website. By continuing to use this site, accepting or closing this box, you consent to our use of cookies. To learn more, visit our privacy policy.