JFIF x x C C " } !1AQa "q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w !1AQ aq"2B #3Rbr{
File "helpers.php"
Full Path: /var/www/laravel_filter/vendor/nwidart/laravel-modules/src/helpers.php
File size: 1.18 KB
MIME-type: text/x-php
Charset: utf-8
<?php
use Illuminate\Foundation\Vite;
use Illuminate\Support\Facades\Vite as ViteFacade;
if (! function_exists('module_path')) {
function module_path($name, $path = '')
{
$module = app('modules')->find($name);
return $module->getPath() . ($path ? DIRECTORY_SEPARATOR . $path : $path);
}
}
if (! function_exists('config_path')) {
/**
* Get the configuration path.
*
* @param string $path
* @return string
*/
function config_path($path = '')
{
return app()->basePath() . '/config' . ($path ? DIRECTORY_SEPARATOR . $path : $path);
}
}
if (! function_exists('public_path')) {
/**
* Get the path to the public folder.
*
* @param string $path
* @return string
*/
function public_path($path = '')
{
return app()->make('path.public') . ($path ? DIRECTORY_SEPARATOR . ltrim($path, DIRECTORY_SEPARATOR) : $path);
}
}
if (! function_exists('module_vite')) {
/**
* support for vite
*/
function module_vite($module, $asset): Vite
{
return ViteFacade::useHotFile(storage_path('vite.hot'))->useBuildDirectory($module)->withEntryPoints([$asset]);
}
}