All Projects → bobmotor → magento-2-gulp

bobmotor / magento-2-gulp

Licence: MIT license
Gulp for Magento 2. It works with core Magento styles (less) and structure. Uses default theme configs from dev/tools/grunt/configs/local-themes.js.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to magento-2-gulp

Kirby Webpack
💪 A Kirby CMS starter-kit with modern frontend tools
Stars: ✭ 150 (+305.41%)
Mutual labels:  less, browsersync, livereload
adfab-gulp-boilerplate
A boilerplate including Gulp, Less/SASS, BrowserSync.
Stars: ✭ 17 (-54.05%)
Mutual labels:  gulp, less, browsersync
Magento2 Frontools
Set of front-end tools for Magento 2 based on Gulp.js
Stars: ✭ 416 (+1024.32%)
Mutual labels:  gulp, browsersync, magento2
Gulp Starter Kit
A simple Gulp 4 Starter Kit for modern web development.
Stars: ✭ 134 (+262.16%)
Mutual labels:  gulp, less
Bootstrap 4 Sass Gulp 4 Boilerplate
A Bootstrap 4.5.2 boilerplate with font-awesome, sass, gulp 4 tasks
Stars: ✭ 103 (+178.38%)
Mutual labels:  gulp, browsersync
Fuzzymail
📨 Email template generator. Making emails fun again.
Stars: ✭ 114 (+208.11%)
Mutual labels:  gulp, livereload
Wordpress Starter
📦 A starter template for WordPress websites
Stars: ✭ 26 (-29.73%)
Mutual labels:  gulp, browsersync
Bootstrap 4 Boilerplate
Bootstrap 4.3.1 boilerplate with Browsersync, Sass and Gulp.js
Stars: ✭ 155 (+318.92%)
Mutual labels:  gulp, browsersync
Glup
Some of the gulp tutorial -《gulp笔记》
Stars: ✭ 136 (+267.57%)
Mutual labels:  gulp, less
module-dsu-client
No description or website provided.
Stars: ✭ 17 (-54.05%)
Mutual labels:  magento-2, magento2
Gulp Webpack Starter
Gulp Webpack Starter - fast static website builder. The starter uses gulp toolkit and webpack bundler. Download to get an awesome development experience!
Stars: ✭ 199 (+437.84%)
Mutual labels:  gulp, browsersync
Frontie Webpack
Front-end Boilerplate | Gulp 4 + Webpack 4 + Babel + ITCSS Architecture + BEM Methodology + Twig.js
Stars: ✭ 102 (+175.68%)
Mutual labels:  gulp, browsersync
Gulp Pug Sass Seed
🍹 A Pug and Sass starter project using gulp for task automation.
Stars: ✭ 84 (+127.03%)
Mutual labels:  gulp, browsersync
Web Starter Kit
Web Starter Kit is an opinionated boilerplate for web development. A solid starting point for both professionals and newcomers to the industry.
Stars: ✭ 130 (+251.35%)
Mutual labels:  gulp, browsersync
Generator Fountain Webapp
Yeoman 'fountain' generator to start a webapp
Stars: ✭ 985 (+2562.16%)
Mutual labels:  gulp, browsersync
Generator Phaser Plus
[🛑 DISCONTINUED] It has been a long journey but development of `generator-phaser-plus` is now over. I recommend you have a look and fork `yandeu/phaser-project-template` instead.
Stars: ✭ 148 (+300%)
Mutual labels:  gulp, browsersync
Compile Hero
🔰Visual Studio Code Extension For Compiling Language
Stars: ✭ 169 (+356.76%)
Mutual labels:  gulp, less
magento2-guest-to-customer
Guest to Customer for Magento2 - Quickly and easily convert existing guest checkout customers to registered customers.
Stars: ✭ 66 (+78.38%)
Mutual labels:  magento-2, magento2
magento2
For any issues or questions please get in touch with us via [email protected]
Stars: ✭ 15 (-59.46%)
Mutual labels:  magento-2, magento2
Blendid
A delicious blend of gulp tasks combined into a configurable asset pipeline and static site builder
Stars: ✭ 5,026 (+13483.78%)
Mutual labels:  gulp, browsersync

Stand With Ukraine

Getting Started

This build supports gulp 4.x.x. For gulp 3.x.x use ~1.4.0 version.

Be sure that Node, NPM and Gulp are installed

node -v && npm -v && gulp -v

Project integration

Add repository's path to the composer.json

"repositories": [
    {
        "type": "github",
        "url": "https://github.com/bobmotor/magento-2-gulp"
    }
],

Run

composer require --dev bobmotor/magento-2-gulp

Rename the following files in your project root directory

  • package.json.example to package.json

Install modules listed as dependencies in package.json

npm install

or

yarn

Configuration

Make sure that you configure dev/tools/grunt/configs/local-themes.js file (adobe docs)

Copy the contents of local.js.example into local.js in the dev/tools/gulp/configs/ directory and setup Gulp configuration.

module.exports = {
    hostname: 'hostname',
    generic: 'loc',
    useHttps: false,
    useInDocker: false
};

Optionally

  • If you need to configure BrowserSync use the dev/tools/gulp/configs/bsConfig.js
module.exports = {
    proxy: `${ptotocol}://${localConfig.hostname}.${localConfig.generic}/`,
    host: `${localConfig.hostname}.${localConfig.generic}`,
    tunnel: `${localConfig.hostname}`,
    open: false
};
  • To configure your desired screen size for the critical path use the dev/tools/gulp/configs/criticalConfig.js
module.exports = {
    out: 'critical.css',
    url: `${ptotocol}://${localConfig.hostname}.${localConfig.generic}/`,
    width: 1920,
    height: 200,
    forceExclude: [/\[data-role=main-css-loader]/]
};

How to use

In project root dir run gulp [command] --[theme] --[arguments]

Avaliable commands:

babel                           Compile ES6+ to ES5
clean                           Remove cached files (pub/static/*, var/*)
critical                        Compile critical css
default, help                   Display this help message
exec                            Republishes symlinks to the source files
less                            Compile LESS to CSS
watch-scripts                   Watch for src/*.js files
watch-styles                    Watch for *.less files

Options:

--[package]                     Package name (optional field). Need to be the first option. Ex.: --blank
--min                           Minify css files
--map                           Add maping to CSS files
--live                          Enable livereload
--bs                            Enable browsersync

Examples:

Removes the theme related static files in the pub/static and var directories, republishes symlinks to the source files to the pub/static/frontend/ directory and compiles CSS files using the symlinks published in the pub/static/frontend/ directory with source map and minification.

gulp clean --luma && gulp exec --luma && gulp less --luma --map --min

Compiles CSS files using the symlinks published in the pub/static/frontend/ directory with source map.

gulp less --luma --map

Watch styles with livereload (LiveReload browser extension should be installed)

gulp watch-styles --luma --live

Creates critical.css from styles-l.css and styles-m.css and put it to app/design/frontend/<VandorName>/<ThemeName>/web/css. In production mode should be run after php bin/magento s:s:d (task uses pub/static/deployed_version.txt to create absolute path to the static files)

gulp critical --luma

Note:

  • ES6 files should be placed at .../web/js/src/*.js. Compiled files will be in the .../web/js/*.js
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].