File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -54,8 +54,8 @@ $dp = new \Le\Dataplater\Dataplater(
54
54
55
55
// optional:
56
56
vars: [ 'var' => 'value', ], // global vars
57
- attr : 'data-custom ', // custom base attribute
58
- baseDir : 'app/templates/ ' // base directory for templates
57
+ baseDir : 'app/templates/ ', // base directory for templates
58
+ attr : 'data-custom ' // custom base attribute
59
59
);
60
60
```
61
61
@@ -64,8 +64,8 @@ The recommended way to initialize the object is by using PHP8's named arguments.
64
64
65
65
Optional parameters:
66
66
- ` vars ` : an array of global vars to pass into the template with keys being the vars' names
67
- - ` attr ` : the base attribute name to use for all attributes (defaults to ` data-dp ` )
68
67
- ` baseDir ` : the base directory to use for includes (defaults to ` . ` )
68
+ - ` attr ` : the base attribute name to use for all attributes (defaults to ` data-dp ` )
69
69
70
70
### ` render() ` method
71
71
Original file line number Diff line number Diff line change @@ -24,8 +24,8 @@ public function __construct(
24
24
?string $ filename = null ,
25
25
?string $ template = null ,
26
26
protected array $ vars = [],
27
- protected string $ attr = 'data-dp ' ,
28
27
protected string $ baseDir = '. ' ,
28
+ protected string $ attr = 'data-dp ' ,
29
29
) {
30
30
if ($ filename === null && $ template === null ) {
31
31
throw new InvalidArgumentException ('must provide either the filename or the template string param ' );
You can’t perform that action at this time.
0 commit comments