We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aa59602 commit f71719dCopy full SHA for f71719d
README.md
@@ -41,9 +41,9 @@ The pattern loader looks for patterns and allows the use of the Pattern Lab-spec
41
42
```php
43
$data = array(...);
44
-$patternPath = "path/to/pattern";
+$patternContent = file_get_contents("path/to/pattern");
45
$patternEngineBasePath = \PatternLab\PatternEngine::getInstance()->getBasePath();
46
$patternLoaderClass = $patternEngineBasePath."\Loaders\PatternLoader";
47
$patternLoader = new $patternLoaderClass($options);
48
-$code = $patternLoader->render(array("pattern" => $patternPath, "data" => $data));
+$code = $patternLoader->render(array("pattern" => $patternContent, "data" => $data));
49
print $output; // outputs the given pattern
0 commit comments