Skip to content

Commit

Permalink
Lazily register blade directives (#104)
Browse files Browse the repository at this point in the history
  • Loading branch information
axlon authored Sep 1, 2022
1 parent 0919dd0 commit 78a521f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/CspServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ public function packageBooted()
return app(NonceGenerator::class)->generate();
});

$this->registerBladeDirectives();
$this->callAfterResolving('view', function () {
$this->registerBladeDirectives();
});
}

private function registerBladeDirectives(): void
Expand Down

0 comments on commit 78a521f

Please sign in to comment.