Skip to content

It would be nice to have an ability to skip the current module name prefix in layout files for CSS/JS declarations like it is possible for templates #2395

@dmitrii-fediuk

Description

@dmitrii-fediuk

See, for example:

<block class="Magento\Catalog\Block\Adminhtml\Product\Edit\Js" name="catalog_product_js" template="catalog/product/js.phtml"/>

<block 
    class="Magento\Catalog\Block\Adminhtml\Product\Edit\Js" 
    name="catalog_product_js" 
    template="catalog/product/js.phtml"
/>

is the same as

<block 
    class="Magento\Catalog\Block\Adminhtml\Product\Edit\Js" 
    name="catalog_product_js" 
    template="Magento_Catalog::catalog/product/js.phtml"
/>

But it is not possible for CSS and JS declarations:

<css src="Magento_Catalog::product/product.css"/>

<css src="Magento_Catalog::product/product.css"/>

It would be nice to have an abilily skip the current module prefix and use some shorter syntax like <css src="product/product.css"/> or <css src="::product/product.css"/>

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions