summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/AssetsServiceProvider.php16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/AssetsServiceProvider.php b/src/AssetsServiceProvider.php
index ba97e21..9e1d40d 100644
--- a/src/AssetsServiceProvider.php
+++ b/src/AssetsServiceProvider.php
@@ -6,7 +6,23 @@ use Illuminate\Support\ServiceProvider;
class AssetsServiceProvider extends ServiceProvider
{
+ public const NAMESPACE = 'laralight-assets';
+
public $singletons = [
Assets::class
];
+
+ public function boot(): void
+ {
+ $ns = static::NAMESPACE;
+ $root = __DIR__ . '/../';
+ $viewsPath = $root . 'resources/views';
+
+ $this->loadViewsFrom($viewsPath, $ns);
+
+ $this->publishes([
+ $viewsPath => resource_path("views/vendor/{$ns}"),
+ ]);
+ }
+
}