Support the ongoing development of Laravel.io →
Configuration Views Installation

Hello,

Few days ago I started to learn new Laravel 5.4 and I have first problems.

Here's code of my mix tasks. First I want to compile my less into css file, next combine all css files into one css file and the same with js. But the problem is to version it. When I use following code:

mix.less('resources/assets/less/clean-blog.less', '../resources/assets/css/clean-blog.css');

mix.combine([
   'resources/assets/css/clean-blog.css',
   'resources/assets/vendor/bootstrap/css/bootstrap.css',
   'resources/assets/vendor/font-awesome/css/font-awesome.css'
], 'public/css/main.css').version();

mix.combine([
    'resources/assets/vendor/jquery/jquery.js',
    'resources/assets/js/clean-blog.js',
    'resources/assets/js/contact_me.js',
    'resources/assets/js/jqBootstrapValidation.js',
    'resources/assets/vendor/bootstrap/js/bootstrap.js',
], 'public/js/main.js').version();

I don't get versioned main.css and main.js, but clean-blog.css. Is there any solution for this problem?

Last updated 3 years ago.
0

Sign in to participate in this thread!

Eventy

Your banner here too?

c00perpl c00perpl Joined 3 May 2015

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.