我正在试图找出如何在我正在处理的主题上删除Drupal 8的默认css库。我尝试使用libraries-override:删除特定的CSS,但它似乎不起作用。css文件仍在显示。正如你所看到的,align.module.css仍然显示在Google上。我不确定我使用的方法是不推荐的还是不正确的

name: Barebones
description: Drupal light
type: theme
core: 8.x
base theme: stable
libraries-override:
system/base:
css:
component:
/core/modules/system/css/components/align.module.css: false

发布于 2017-11-22 08:54:05
也许有帮助(没有测试)
libraries-remove
删除整个库的能力。
图书馆-删除:
libraries-override
覆盖整个库和库的部分的能力:
libraries-override:
# Replace an entire library.
core/drupal.collapse: mytheme/collapse
# Replace an asset with another.
subtheme/library:
css:
theme:
css/layout.css: css/my-layout.css
# Remove an asset.
drupal/dialog:
css:
theme:
dialog.theme.css: false
# Remove an entire library.
core/modernizr: falsehttps://stackoverflow.com/questions/47430080
复制相似问题