optimistdigital/laravel-create-frontend
Maintainers
Package info
github.com/outl1ne/laravel-create-frontend
pkg:composer/optimistdigital/laravel-create-frontend
v2.0.0
2019-04-22 13:36 UTC
Requires
None
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
MIT ebbbb408c4a8b75b87711267fb56535811935800
- Allan Tatter <allan.tatter.woop@gmail.com>
This package is auto-updated.
Last update: 2026-06-25 16:59:53 UTC
README
This package adds a Laravel helper method to include the js and css files from create-frontend in your html. It grabs the right path for the versioned files from asset-manifest.json
Usage
1. Install the package:
composer require optimistdigital/laravel-create-frontend
2. Add this to your html:
<script src="{{ frontend('app.js') }}"></script>
3. For production, also include css:
<link rel="stylesheet" type="text/css" href={{ frontend('app.css') }}>
API
/**
* $assetName - name of the unhashed asset in your manifest
* $manifestPath - location of your manifest - optional, defaults to public/build/asset-manifest.json
*/
frontend($assetName, $manifestPath)
