Coder Social home page Coder Social logo

loewy-assets's People

Contributors

agopshi avatar dan-hhog avatar kbauer-hhog avatar sukiman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

loewy-assets's Issues

Implement `gulp-plumber` for `js` and `styles` tasks

Please implement the gulp-plumber monkey-patch for the js and styles tasks. Basically, you need to pipe through plumber() before any other tool. This prevents broken pipes from stalling the entire stream. (e.g. if something goes wrong with the Sass pipe, it won't hang the whole watch process, it'll just keep going)

Sass outputting error "file to import not found or unreadable"

When using gulp or gulp watch with the default sass task, sometimes, errors like this appear:

[gulp] Finished 'css' after 11 ms
[gulp] Starting 'sass'...
Error in plugin 'sass'
Message:
    wp-content\themes\example\assets\dev\scss\main.scss
  11:9  file to import not found or unreadable: components/widgets/events
Current dir:
[gulp] Finished 'sass' after 66 ms

The files in question do exist, and are readable. This seems to be some sort of intermittent issue.

SCSS and CSS watches conflict

Looks like there are conflicts between the SCSS and CSS watches when multiple CSS files are generated by the SCSS compilation. The CSS watch ends up executing the css task multiple times (once per output CSS file), and that causes read/write issues.

To fix this, we should simplify the sass.js and css.js tasks into a single styles.js task which does the following:

  1. Watch for updates to SCSS files. (Currently in sass.js.)
  2. Compile the SCSS into CSS. (Currently in sass.js.)
  3. Move the CSS files into the development CSS directory. (Currently in sass.js.)
  4. Run autoprefixer. (Currently in css.js.)
  5. Move the final CSS files into the release CSS directory. (Currently in css.js.)

Implement Babel for JS task

Let's implement the Babel transpiler for the JS task. Should a simple one-line addition in tasks/js.js (before the concat call). Extract the Babel options in config.js.babel, and provide sensible defaults (like { presets: ['es2015'] }).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.