GithubHelp home page GithubHelp logo

isabella232 / web3studio-standards Goto Github PK

View Code? Open in Web Editor NEW

This project forked from consensysmesh/web3studio-standards

0.0 0.0 0.0 432 KB

Standards repo for sharable linting and configuration tools

License: Apache License 2.0

JavaScript 85.66% Shell 14.34%

web3studio-standards's Introduction

Web3Studio Standards

A collection of boilerplate config to be used by Web3Studio projects.

Installation

$ yarn add --dev eslint-config-web3studio eslint prettier pretty-quick husky

# For projects with Smart Contracts
$ yarn add --dev solhint-config-web3studio solhint prettier-plugin-solidity

In your .eslintrc.js file:

module.exports = {
  extends: [
    'web3studio',
    'web3studio/truffle' // For projects using truffle
  ]
};

In your .prettierrc.js file:

module.exports = require('eslint-config-web3studio/prettier');

In your .solhint.json file:

{
  "extends": ["solhint:recommended", "web3studio"]
}

In your package.json file:

{
  "husky": {
    "hooks": {
      "pre-commit": "pretty-quick --staged"
    }
  },
  "scripts": {
    "lint": "yarn lint:js && yarn lint:sol",
    "lint:js": "eslint .",
    "lint:sol": "solhint \"**/*.sol\"",
    "prettier": "prettier \"**/*.{js,json,css,md,sol}\" --write"
  }
}

Releasing a New Version

NB: For maintainers only.

web3studio-standards uses Semver for versioning. Based on the changes since the last release, determine which type of release this is, major, minor, or patch.

Use lerna to update all of the packages to the new version, and create a pull request. Travis will handle publishing to npm.

For example, to release a new major version...

$ git checkout -b release/v1.0.0
$ yarn lerna:version major
$ git push origin release/v1.0.0 --follow-tags

# Open a pull request from `release/v1.0.0` => `master`

License

Apache 2.0

web3studio-standards's People

Contributors

barlock avatar

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.