/** * Return the public path to an asset. * path to return is relative to package template folder. * If you want to return an asset relative to the public folder, * use larvel's asset() instead * @param string $asset The asset * @return string */ function cd_naradmin_asset($asset = null) { $pathToAssets = env('CD_ASSETSPATH', false); if (!empty($pathToAssets)) { return fixDoubleSlash($pathToAssets . '/' . $asset); } return asset('assets') . '/' . fixDoubleSlash(cd_naradmin_tag() . '/templates/' . cd_template() . '/' . $asset); }
public function boot() { // Define the path for the view files $this->loadViewsFrom(__DIR__ . '/../resources/views', cd_naradmin_tag()); $this->publishes([__DIR__ . '/../resources/assets' => public_path('assets/naradmin')], 'public'); $this->publishes([__DIR__ . '/../resources/views' => base_path('resources/views/claremontdesign/naradmin')], 'views'); $this->publishes([__DIR__ . '/../database/migrations' => base_path('database/migrations')], 'migrations'); // Loading the routes file require __DIR__ . '/Http/routes.php'; }