Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@networkteam/gulpfile

Package Overview
Dependencies
Maintainers
3
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@networkteam/gulpfile

An opinionated frontend workflow based on jonnitto/gulpfile.js

  • 1.2.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
3
Created
Source

license npm Build Status

@networkteam/gulpfile

@networkteam/gulpfile is a so called hard-fork of the public package gulpfile.js by jonnitto .

The main reason behind this kind of fork is the way we want to use this package. It is inspired by the package.json of create-react-app.

Usage

Make sure Node installed. I recommend using NVM to manage versions.

Install Dependencies

If you use this library the first time, you need to be shure all global dependencies are installed correctly:

# Install Yarn
brew update
brew install yarn
gem install scss_lint

If the global dependencies are installed, you can install the rest with yarn.

Run Gulp

If you have gulp installed globally, you can simple run gulp, optional with some flags. With gulp -T you can print out all the options. If there's a global gulp in a different version, you have to use this commands:

CommandWatcherBehaviour
yarn startxGenerates all Assets, Javascript and CSS files
yarn run tasksShow all available tasks
yarn run beautifyxBeautify and dont't compress files
yarn run debugxFiles dont't get compressed and sourcemaps get genereated
yarn run mapsxWrite sourcemaps
yarn run buildRuns the build process for production
yarn run cssRender CSS Files
yarn run scssRender _all.scss and _allsub.scss Files
yarn run jsRender Javascript Files
yarn run imagesOptimize images and overrite them in the source folder

Overview

FeaturesTools Used
CSSSass (Libsass via node-sass) and PostCSS
JavascriptRollup JS with Bublé or Babel
ImagesCompression with imagemin. Run width gulp optimizeImages. Overwrites files in the resource folder.
IconsAuto-generated SVG Sprites and/or Icon Fonts
LintScssLint and ESLint included

You can configure the behaviour with the gulp.json in the root folder. To turn of a certain task, for example, just do it like this:

{
	"tasks": {
		"js": false
	}
}

Take a look into config.json the figure out which options are available. The script loads also the informations (description, author and homepage entry) from composer.json

CSS

SCSS

These small helpers can make your developer life much easier. These files get filled automatically by the gulp task scss

FilenameDescription
_all.scssEvery file from the same directory get an @import statement. Files with beginning underscore (_) get ignored.
_allsub.scssEvery file from sub directories an @import statement. Files and folders with beginning underscore (_) get ignored.

PostCSS

Following plugins are included:

PluginDescription
postcss-rtlPostCSS plugin for RTL-optimizations. Turned off by default
postcss-assetsPostCSS plugin to manage assets
postcss-magic-animationsPlugin that adds @keyframes from Magic Animations
postcss-vmaxUse vmax units in Edge and Internet Explorer
postcss-shortShort creates and extends shorthand properties in CSS
postcss-centerPostCSS plugin to center elements
postcss-grid-kissA PostCSS plugin to keep CSS grids stupidly simple
rucksack-cssA little bag of CSS superpowers
postcss-flexboxFlexbox layouts made easy with PostCSS
pleeease-filtersConvert CSS shorthand filters to SVG ones
postcss-selector-matchesPostCSS plugin to transform :matches() W3C CSS pseudo class to more compatible CSS selectors
postcss-selector-notPostCSS plugin to transform :not() W3C CSS leve 4 pseudo class to :not() CSS level 3 selectors
postcss-pseudoelementsPostCSS plugin to add single-colon CSS 2.1 syntax pseudo selectors (i.e. :before)
postcss-quantity-queriesPostCSS plugin enabling quantity-queries
postcss-fixesPostCSS plugin to fix known Browser Bugs.
css-mqpackerPack same CSS media query rules into one media query rule.
postcss-round-subpixelsPlugin that rounds sub-pixel (eg: 12.87378px) values to the nearest full pixel.
postcss-reporterLog PostCSS messages in the console
postcss-pxtoremA plugin for PostCSS that generates rem units from pixel units.
cssnanoMinify & autoprefix final css files

Plugins for Editors

Atom

PackageCommand
ScssLint apm install linter-scss-lint
ESLintapm install linter-eslint
Fusion apm install language-typoscript2

PhpStorm and WebStorm

Releasing

Create a new version with npm version ..., e.g. for a patch release:

npm version patch

This will automatically push the tags to the repository and trigger a release to the NPM registry via a Travis CI build.

License

Licensed under MIT, see LICENSE

Keywords

FAQs

Package last updated on 06 Jun 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc