Skip to content

Commit

Permalink
Updated based on PR feedback
Browse files Browse the repository at this point in the history
Updated to specifically check for .css or .scss as per recommendation.
  • Loading branch information
gRoberts84 authored Jun 4, 2024
1 parent 588ce53 commit 00152cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Assets.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public function inject(array|string $entrypoint, array $customOptions = []): voi

add_action($action, function () use ($entries, $options) {
array_map(function($entry) use ($options) {
$tag = str_ends_with($entry, 'css')
$tag = str_ends_with($entry, '.css') || str_ends_with($entry, '.scss')
? array_key_first($this->getStyleTags($entry, $options))
: $this->getScriptTag($entry, $options);

Expand Down

0 comments on commit 00152cf

Please sign in to comment.