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

@devcode/init

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@devcode/init

The glue for DevCode plugins

  • 0.1.20
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

DevCode Init

DevCode management for DevCode's plugins. It contains Gulp tasks: default, build, clean, watch and init-config.

Getting started

Prerequisites

What things you need:

  • Node.js + npm (already included in Node.js)
  • Gulp

How to install

Install it as devDependency:

npm install -D @devcode/init

How to use

Include it in gulpfile.js:

const gulp = require('gulp')
const init = require('@devcode/init')
const plugins = {
  browserSync: require('@devcode/browser-sync')
}
const env = process.argv.includes('build') ? 'production' : 'development'

init({
  gulp, // required
  env, // required
  plugins: { // required
    reload: [plugins.browserSync],
    assets: [...],
    code: [...],
    static: [...]
  }
})

API

init: function (settings: object)

The init function needs env (string 'development' or 'production') and plugins which contains four keys: reload, assets, code and static. Each key can contain array of plugins. In the Gulp tasks default and build are plugins kept in the chronological order: clean, [plugins.assets], [plugins.code], [plugins.static], and for the default task as the last is (watch).

Configuration

  • src: string - name of the folder with source code
  • dist: string - name of the folder with distribution code
module.exports = {
  src: 'src',
  dist: 'build'
}

Built with

  • Gulp - the streaming build system
  • gulp-sequence - runs a series of gulp tasks in order
  • del - deletes files and folders using globs
  • Prettier - the opinionated code formatter

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Versioning

We use SemVer for versioning.

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

Acknowledgements

  • This project was inspired by Blendid

Keywords

FAQs

Package last updated on 29 Nov 2017

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