laravel-elixir

Elixir + Gulp + Laravel with differents JS inclusions depending on URL

[亡魂溺海] 提交于 2020-01-17 03:23:05
问题 I'd like to begin use Elixir + Gulp. In my project, I just use CSS + JS. Today, I use it like that: I have a dashboard.blade.php that I include in all files. Then, I have a conditional include for each libs depending on the page: @if (Request::is("tournaments") || Request::is("invites")) {!! Html::script('js/plugins/tables/footable/footable.min.js') !!} @endif @if (Request::is("tournaments/create")) {!! Html::script('js/plugins/forms/inputs/duallistbox.min.js') !!} {!! Html::script('js

Foundation with Laravel and Elixir

江枫思渺然 提交于 2019-12-31 22:39:35
问题 How should one use Foundation with Laravel? I thought I'd install Foundation in vendor folder with bower install foundation . This results into having a vendor/bower_components folder where I have Foundation and all required libraries such as jQuery. What should I add in gulpfile.js for Elixir to interpret this correctly? It should be possible to update Bower components install new Bower packages modify Foundation Sass variables without these being overwritten when updating use Compass In a

laravel 5 - css file is not defined in asset manifest?

谁说我不能喝 提交于 2019-12-31 19:38:48
问题 I get an Error Message with laravel 5, which I don't understand. Next exception 'ErrorException' with message 'File build/css/all.css not defined in asset manifest. I haven't installed any asset pipeline or something. Just used elixir to compile, minify and version the scss-file to all.css and included it into the master view with <link rel="stylesheet" href="{{ elixir("css/all.css") }}"> What is this 'asset manifest' and how to fix this error?` 回答1: The question is of course what you want to

laravel 5 - css file is not defined in asset manifest?

蹲街弑〆低调 提交于 2019-12-31 19:38:15
问题 I get an Error Message with laravel 5, which I don't understand. Next exception 'ErrorException' with message 'File build/css/all.css not defined in asset manifest. I haven't installed any asset pipeline or something. Just used elixir to compile, minify and version the scss-file to all.css and included it into the master view with <link rel="stylesheet" href="{{ elixir("css/all.css") }}"> What is this 'asset manifest' and how to fix this error?` 回答1: The question is of course what you want to

glyphicons not showing with sass bootstrap integration

末鹿安然 提交于 2019-12-30 17:25:14
问题 I used this tutorial to integrate bootstrap in my project: https://laravel-news.com/2015/10/setup-bootstrap-sass-with-laravel-elixir/ This places an app.css file in the css folder. However if I try to use glyphicons they don't show up. So I tried to modify the elixir file like this: elixir(function(mix) { mix.sass('app.scss') .browserify('app.js') .copy('node_modules/bootstrap-sass/assets/fonts', 'public/css/fonts') }); The fonts folder is copied under public/css/fonts but yet no icon shows

Cannot find module 'gulp-util'

扶醉桌前 提交于 2019-12-24 06:59:14
问题 I have some trouble with gulp. I use laravel/elixir which has gulp as its dependency. I did the steps like here Can't get Gulp to run: cannot find module 'gulp-util' but still no success. Actually the gulp-util files are inside the node_modules folder... Anyway I'm using Xubuntu 17.04 64bit if it counts. 回答1: I had the same problem, and tried almost everything. But then I realized that the error does not point to the local gulp in the respective project but to the global one (/usr/lib/nodejs

Installing CKEditor with npm

有些话、适合烂在心里 提交于 2019-12-22 08:16:14
问题 I am trying to install CKEditor in my project. I am using Laravel. I know I could download the files but I like making my life difficult and I decided that I want to install CKEditor as a npm dependency. As stated in their documentation here, I added the package to package.json, like this: "dependencies": { "jquery": "^1.11.1", "bootstrap-sass": "^3.0.0", "elixir-coffeeify": "^1.0.3", "laravel-elixir": "^4.0.0", "font-awesome": "^4.5.0", "ckeditor": "^4.5.7" } Now I guess I have to require it

Delete intermediary files after elixir merge

為{幸葍}努か 提交于 2019-12-21 19:44:03
问题 I am using Laravel 5. During gulp task, the processed SASS files and other CSS files copied from resource folder are stored in public/css. Then all the files in the public/css are merged together to a single file as "all.css". So the files that were created needs to be deleted. How can I do this? 回答1: For newer versions of laravel this worked for me: var elixir = require('laravel-elixir'); var del = require('del'); elixir.extend('remove', function(path) { new elixir.Task('remove', function()

Module not found: Error: Can't resolve 'fs'

蹲街弑〆低调 提交于 2019-12-20 01:03:47
问题 I working on a Laravel 5.3 project. I am getting below errors when I am running gulp command in CMD. Could anyone say how can I get a error less result ? gulpfile.js var elixir = require('laravel-elixir'); require('laravel-elixir-vue'); elixir(function(mix) { mix.sass('app.scss'); }); elixir(function(mix) { mix.webpack('app.js'); }); elixir(function(mix) { mix.version(['css/app.css', 'js/app.js']); }); package.json { "private": true, "scripts": { "prod": "gulp --production", "dev": "gulp

Gulp Error: watch ENOSPC

核能气质少年 提交于 2019-12-19 06:20:28
问题 Hi i'm getting this error while running gulp watch. im using vueify in laravel project. why is this happening. it was working fine all these days and this came in today. $ gulp watch [12:56:01] Using gulpfile ~/Documents/web_projects/next-home/gulpfile.js [12:56:01] Starting 'watch'... [12:56:01] Starting 'browserify'... Fetching Browserify Source Files... - resources/assets/js/app.js Saving To... - public/js/app.js [12:56:02] Finished 'browserify' after 707 ms [12:56:02] 'watch' errored