FAQ Database Discussion Community


Laravel 5 elixir: How do I Compile and move .scss files?

css,laravel,sass,laravel-5,laravel-elixir
I have tried to follow the instructions at laravel-elixir, but I'm apperantly still to green to get it, so I hope you can explain it to me in a more beginner-friendly way. I want to use elixir to compile my scss from resources/assets/scss/styles.scss and then output the file to public/styles.css...

Laravel Elixir includePaths not working

php,laravel,bootstrap-sass,laravel-elixir
I'm trying Laravel Elixir and want to include bootstrap with includePaths but it does not work. Where am I going wrong? var paths = { 'bootstrap': './vendor/bower_components/bootstrap-sass-official/assets/' } elixir(function(mix) { mix.sass("style.scss", 'public/assets/css/', {includePaths: [paths.bootstrap + 'stylesheets/']}) }); ...

Laravel Elixir Sass Compilation - .sass files

laravel,sass,laravel-elixir
I'm a bigger fan of .sass syntax over the .scss syntax (because it's better, let the war begin!), so that's what I'm trying to use. When trying to compile a .sass file with Elixir, however, it seems to be trying to use scss syntax to compile. elixir(function(mix) { mix.sass('styles.sass'); });...

Compiling assets subdirectories in Gulp with Laravel Elixir

php,laravel,gulp,laravel-5,laravel-elixir
I am working on what will end up being a very large application, which means my asssets/whatever folders are going to contain possibly a few hundred files (SCSS, js etc). Obviously this will make managing them a little tricky, so I would like to arrange them into subfolders for each...

Running gulp tasks with laravel elixir doesnt version all js files

laravel,gulp,laravel-5,laravel-elixir
I have this gulpfile.js https://gist.github.com/kristapsveveris/c25ba60984d8f3602d68 When I run gulp task, the result is : rev-manifest.json contains : { "assets/js/all.js": "assets/js/all-d764f790.js", "assets/css/all.css": "assets/css/all-189848ae.css", "assets/css/serve-desktop.css": "assets/css/serve-desktop-037f21da.css", "assets/css/serve-mobile.css": "assets/css/serve-mobile-b0a650b6.css" } So the problem is that versioning doesn't create 'campaign.js' and 'serve.js' only their .map files And if I run : gulp --production &&...

Laravel 5 Elixir + gulp mix and version multiple css or less files

laravel,gulp,laravel-elixir
I have a separate css/less file for my landing / login page. How do I tell gulp, that it should compile two files for me? Here is my approach which generates unfortunately only one file for me. elixir(function (mix) { // only for the landing-page mix.less('landing.less') .version('css/landing.css'); // for the...

Laravel elixir - more specific error messages from gulp

less,gulp,laravel-elixir
I'm receiving the following error when trying to compile the less files for a theme that I purchased that was packaged with less files. Here's the output I'm seeing: $ gulp [22:53:49] Using gulpfile ~/path/to/gulpfile.js [22:53:49] Starting 'default'... [22:53:49] Starting 'less'... [22:53:49] Running Less: resources/assets/less/style.less [22:53:49] Finished 'default' after 524...

gulp cannot find module 'notify-send' on Laravel 5 Homestead

sass,gulp,laravel-5,homestead,laravel-elixir
I'm working with Laravel 5 (Elixir) and homestead v2.5 in Ubuntu 14.10. When I typed gulp and press enter in homestead ssh, I found the following error: Error: Cannot find module './lib/notifiers/notify-send' at Function.Module._resolveFilename (module.js:338:15) at Function.Module._load (module.js:280:25) at Module.require (module.js:364:17) at require (module.js:380:17) at Object.<anonymous> (/home/vagrant/Code/rumta/node_modules/laravel-elixir/node_modules/gulp-notify/node_modules/node-notifier/index.js:2:12) at Module._compile...

Laravel Elixir and Bower: Mixing javascript issue

laravel,bower,laravel-5,laravel-elixir
I have my Bower vendor directory at resources/assets/vendor. In my gulpfile, I've tried the following: mix.scripts([ "vendor/jquery/dist/jquery.min.js" ], "public/js"); When I run gulp in terminal, it doesn't seem to do anything. No errors though. I also tried this: mix.copy('vendor/jquery/dist/jquery.min.js', 'public/js/jquery.js'); To no avail. What am I missing? update & solution...

How do I prevent gulp watch from crashing (e.g. stop watching) when using elixir in laravel 5?

laravel-5,gulp,gulp-watch,laravel-elixir
So I like elixir a lot. But when I run gulp watch and write css (scss to be precise), it crashes after a couple of saves, thus forcing me to start gulp watch again. And it is driving me crazy, almost to the point of me not being able to...

Laravel Elixir include Paths for less

php,less,laravel-5,laravel-elixir
I'm trying Laravel Elixir and I want to include bootsrap less files with includePaths like in Elixir saass var paths = { 'bootstrap': './vendor/bower_components/bootstrap-sass-official/assets/' } elixir(function(mix) { mix.sass("style.scss", 'public/assets/css/', {includePaths: [paths.bootstrap + 'stylesheets/']}) }); Is there something similar for less?...

Laravel Elixr copy method not working

php,laravel,laravel-5,laravel-elixir
I am trying to copy some js files, using elixr, from my vendor/bower_components folder, but when running gulp they don't copy across. elixir(function(mix) { mix.less('app.less') .copy('underscore/underscore.js', 'public/js/vendor/underscore.js'); }); No error is given by gulp. [14:12:58] Using gulpfile ~/Public/balloonprinting_l5/gulpfile.js [14:12:58] Starting 'default'... [14:12:58] Starting 'less'... [14:12:58] Running Less: resources/assets/less/app.less [14:12:59] Finished...

Laravel elixir - don't generate map files

laravel,gulp,laravel-elixir
The question is - how to force Laravel Elixir not to generate map files? At the moment if I run gulp I will have generated app.css and app.css.map file. I don't know what for is this app.css.map file but I think it's not necessary for me at the moment. Question...

How to require other CoffeeScripts files in main CoffeeScript with Laravel?

php,laravel,coffeescript,asset-pipeline,laravel-elixir
I have one CoffeeScript project with "Ruby on Rails" framework. Now I want to use "Laravel" framework instead of "Ruby on Rails". In "Ruby on Rails", there is "Sprocket" asset pipeline management library. With "Sprocket", I can import other coffeescript files in main coffeescript file with #= require or #=...

Laravel 5 elixir issue

laravel,assets,gulp,laravel-5,laravel-elixir
I'm having a little issue with elixir in laravel 5. Sass is working fine, but my scripts are not being moved to the public/js directory neither versioned. here is my gulpfile elixir(function(mix) { mix.sass('aracademia.scss') .scripts( [ 'partials/fancybox/jquery.fancybox.pack.js', 'partials/jscroll.js', 'aracademia.js', 'partials/doubletaptogo.js' ], 'resources/assets/scripts', 'public/js/aracademia.min.js'); mix.version(['public/css/aracademia.css','public/js/aracademia.min.js']); }); Any ideas?...

Elixir not creating multiple css files

css,laravel,sass,laravel-elixir
Tried to find an awnser to this question but could not find it here? I'm using Laravel Elixir and got the following in my gulpfile: mix.sass(['app.scss', 'admin.scss'], 'public/css'); Can someone tell me why it is not creating two css files but compiles it into one? How can I achieve it...

Laravel Elixir - adding watch paths

angularjs,laravel,gulp,laravel-elixir
I'm building an Angular application and so have a lot of HTML templates for Angular. My Elixir setup copies these templates into the public folder. However, I've noticed that the watchers are not triggered when assets are modified (so I don't have to rerun Gulp every time I change a...

use laravel elixir npm to manage front dependencies

php,angularjs,laravel-elixir
we are able to load angularjs or other js framework using npm as manager of dependencies. I am in doubt on how to use gulp to load all the dependencies from node_modules folder and later concat all files into single file. I'm also aware the use of browserify. But it...

Gulp didn't install on Laravel Homestead VM (from Windows) and no node_modules folder exists in the directory with package.json?

laravel,gulp,node-modules,homestead,laravel-elixir
I got Laravel Homestead up and running, except when I issue this ssh command: gulp I get this error: Local gulp not found in ~/projects/laravel Try running: npm install gulp That's when I noticed there was no node_modules folder at all in this directory. Weird. Is this an issue where...

Laravel Elixir not combining scripts

php,laravel,laravel-5,laravel-elixir
I just did a clean install of laravel. Elixir is not combining my scripts. I am clueless about what's happening. I see the scripts task getting triggered but no files are output in public/js directory. This is my gulpfile.js: elixir(function (mix) { mix.sass('style.scss') .scripts([ 'vendor/jquery.js', 'vendor/foundation.min.js', 'script.js' ], 'resources/assets/js', 'public/js/app.min.js')...