New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@springtree/coding

Package Overview
Dependencies
Maintainers
5
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@springtree/coding

The SpringTree coding guidelines and helper scripts

  • 1.0.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3
decreased by-76.92%
Maintainers
5
Weekly downloads
 
Created
Source

SpringTree coding guidelines

This repository contains information about our company rules and guidelines when it comes to writing software. Our primary development language is JavaScript/TypeScript so those will be featured here prominently. A collection of configuration files for various tools and linters that can be used in our projects can also be found here.

Style guide

We have adopted the Airbnb style guide for our JavaScript and TypeScript projects. This is a very widely used standard and support is available in a multitude of editors and CI tools. All new projects must use this style guide. When coding on an existing project adhere to the cureent style used throughout the project. This repository contains configuration files for eslint and tslint.

You can install these tools using npm:

npm i -D eslint eslint-config-airbnb eslint-plugin-jsx-a11y eslint-plugin-react eslint-plugin-import tslint tslint-config-airbnb

Human language

All code, variable names, code comments and documentation should be written in English.

Project README

Every project needs to have a README.md (or equivalent) that must contain:

  • the name and purpose of the project
  • how to run the project
  • how to build the project

Any additional information about how to run unit tests should be added if available.

Git flow AVH

We use Git flow AVH as our branching stategy. You can install this on a Mac using Homebrew

brew install git-flow-avh

We have a whole wiki page dedicated to how we use Git flow to perform releases. Try to contain work in separate feature branches as much as possible.

Git branch protection

Projects on GitHub should be setup with branch protection to now allow direct pushes to the master and develop branches. The restriction on master is also enforced for administrators.

Git commit log format

We use the Angular commit log format which we enforce using a combination of commitlint and husky.

You can install these tools using npm:

npm i -D husky @commitlint/cli @commitlint/config-angular

Add the following husky hook to your package.json to enforce the format:

  "husky": {
    "hooks": {
      "commit-msg": "commitlint -E HUSKY_GIT_PARAMS"
    }
  },

Create a commitlint configuration files:

echo "module.exports = { extends: ['@commitlint/config-angular'] }" > commitlint.config.js

Build using CI

All projects should be built using a CI and should not depend on the build chain of an individual developers laptop. This should preferable be setup at project inception.

We use the folloing CI's at this time:

Use tools like docker to encapsulate your build chain.

Pull request validation with CI

Pull requests should be setup to use the CI to validate the branch is building. If available this should include running the unit test suite.

Keywords

FAQs

Package last updated on 07 Mar 2019

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