Skip to content

Commit 4d33681

Browse files
authored
Merge pull request #3 from MaplePHP/develop
Add DTO v3.0.0 support
2 parents 8990641 + 211572b commit 4d33681

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

Dom/Document.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,10 @@ public function bindTag(string $tag, string $key, bool $prepend = false): Elemen
9797

9898
/**
9999
* Create (append) element
100-
* @param string $element HTML tag (without brackets)
101-
* @param string $value add value to tag
100+
*
101+
* @param string $element HTML tag (without brackets)
102+
* @param null $value add value to tag
103+
* @param string|null $bind
102104
* @return ElementInterface
103105
*/
104106
public function create($element, $value = null, ?string $bind = null): ElementInterface
@@ -172,6 +174,7 @@ public function getTag(string $key): ?string
172174
public function execute(?callable $call = null): string
173175
{
174176
$this->html = "";
177+
175178
if (is_null($this->elements)) {
176179
if (method_exists($this, "withElement")) {
177180
$inst = $this->withElement();
@@ -181,6 +184,7 @@ public function execute(?callable $call = null): string
181184
if (is_array($this->elements)) {
182185
$this->build($this->elements, $call);
183186
}
187+
184188
return $this->html;
185189
}
186190

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "maplephp/swiftrender",
33
"type": "library",
4-
"version": "v2.0.0",
4+
"version": "v2.0.1",
55
"description": "PHP SwiftRender is a pure and highly portable PHP template library.",
66
"keywords": ["output buffer", "template", "engine", "partials", "components", "views"],
77
"homepage": "https://wazabii.se",
@@ -18,7 +18,7 @@
1818
],
1919
"require": {
2020
"php": ">=8.0",
21-
"maplephp/dto": "^2.0",
21+
"maplephp/dto": "^3.0",
2222
"maplephp/container": "^1.0"
2323
},
2424
"autoload": {

0 commit comments

Comments
 (0)