Skip to content

Commit 1d4a08e

Browse files
committed
Drupal 11 support
1 parent 7888e3e commit 1d4a08e

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Twig Attribute Extension
22
=======================
3-
Twig is desperately missing wrapper function to handle HTML Attributes. I borrowed great [Attribute](https://api.drupal.org/api/drupal/core%21lib%21Drupal%21Core%21Template%21Attribute.php/class/Attribute/9.2.x) class from Drupal. It collects, sanitizes, and renders HTML attributes in a nice way.
3+
Twig is desperately missing wrapper function to handle HTML Attributes. I borrowed great [Attribute](https://api.drupal.org/api/drupal/core%21lib%21Drupal%21Core%21Template%21Attribute.php/class/Attribute/11.x) class from Drupal. It collects, sanitizes, and renders HTML attributes in a nice way.
44

55
This package was created based on issue [#2664570 - Move Attribute classes under Drupal\Component](https://www.drupal.org/project/drupal/issues/2664570) which created groundwork for using this class outside Drupal world. Unfortunately I had to copy code out because issue is still open. I hope issue will be merged soon, so I can switch to official component split off from Drupal core with proper attribution. Expected component should be available at [https://github.com/drupal/core-attribute](https://github.com/drupal/core-attribute)
66

composer.json

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,9 @@
55
"homepage": "https://github.com/parisek/twig-attribute",
66
"license": "GPL-2.0-or-later",
77
"require": {
8-
"php": ">=8.1.0",
9-
"drupal/core-render": "^9.0|^10.0",
10-
"drupal/core-utility": "^9.0|^10.0",
11-
"twig/twig": "^2.4|^3.0"
8+
"drupal/core-render": "^10.0 || ^11.0",
9+
"drupal/core-utility": "^10.0 || ^11.0",
10+
"twig/twig": "^2.4 || ^3.0"
1211
},
1312
"autoload": {
1413
"psr-4": {

0 commit comments

Comments
 (0)