Skip to content

Commit 1c7f684

Browse files
committed
refactor: enhance asset registration logic in MarkdownEditorExtendedServiceProvider
1 parent 7aba923 commit 1c7f684

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/MarkdownEditorExtendedServiceProvider.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,14 @@ protected function getAssets(): array
6666
{
6767
$scriptPath = __DIR__ . '/../resources/dist/filament-markdown-editor-extended.js';
6868

69+
$asset = Js::make('filament-markdown-editor-extended-scripts', $scriptPath);
70+
71+
if (file_exists($scriptPath)) {
72+
$asset->package('iniznet/filament-markdown-editor-extended:' . filemtime($scriptPath));
73+
}
74+
6975
return [
70-
Js::make('filament-markdown-editor-extended-scripts', $scriptPath),
76+
$asset,
7177
];
7278
}
7379

0 commit comments

Comments
 (0)