Skip to content

iankov/asset-v

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Installation

composer require iankov/asset-v

Publish config file

php artisan vendor:publish --tag=assetv_config

Usage

Run console command to find file modifications and update file version number. Every time file changes it will get a version number incremented by 1

php artisan assetv:update

Use it just as regular asset() function in your laravel application

<script src="{{ asset_v('/js/app.js') }}"></script>

It will make a url with version tail like this

<script src="http://example.com/js/app.js?v2"></script>