Closed Cipa closed 1 year ago
not sure, but i added this from someones fork related to custom directives
if(config('blade.autoload_custom_directives')) {
$blade = app('blade.compiler');
$string_blade = app('stringblade.compiler');
collect($blade->getCustomDirectives())
->each(function($directive, $name) use ($string_blade) {
$string_blade->directive($name, $directive);
});
}
A solution I found is:
$parsedContent = \View::make(['template' => Blade::compileString($this->content)], ['token' => 'I am the child template'])->render();
Hi,
I am trying to use this package in a Resource like below
$this->content has a custom directive:
<p>@tv('test') Error voluptate</p>
The blade directive is:
What would it take to have something like this working:
'parsedContent' => StringBlade::compileString($this->content)
Thank you.