By pancho on
Change record status:
Draft (View all draft change records)
Project:
Introduced in branch:
12.1.x
Introduced in version:
12.1.0
Issue links:
Description:
AttachedAssets has a new createFromAttachments() factory.
Instead of wrapping an existing array of attachments in a temporary render array or initializing AttachedAssets from ground up, the attachments array may now be passed directly to AttachedAssets::createFromAttachments() to initialize an AttachedAssets collection with libraries and JavaScript settings:
$assets = AttachedAssets::createFromAttachments($attachments)
Impacts:
Module developers