Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
In hook_page_attachements() you need to add a condition only when reaction field pages should call the library. Otherwise you can add in field formatter element itself. It will call only the formatter loads in a page.
Comment | File | Size | Author |
---|---|---|---|
#3 | added_attachments_in_a_formatter-2956249-3.patch | 1.11 KB | padma28 |
Comments
Comment #2
padma28 CreditAttribution: padma28 at Valuebound commentedComment #3
padma28 CreditAttribution: padma28 at Valuebound commentedAdded attachments in formatter. Please review.
Comment #4
MRPRAVIN CreditAttribution: MRPRAVIN at Valuebound commentedLooks fine. Reviewed.
Comment #6
padma28 CreditAttribution: padma28 at Valuebound commented