New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

angular-configuration

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

angular-configuration

Add tslint to your rulesDirectory and extend base configuration:

latest
npmnpm
Version
0.5.0
Version published
Maintainers
1
Created
Source

TSLINT

Add tslint to your rulesDirectory and extend base configuration:

{
  "rulesDirectory": [
    "node_modules/codelyzer"
  ],
  "extends": ["./node_modules/angular-configuration/tslint.json"]
}

Usage in package.json:

"scripts": {
  "ts-lint": "ng lint"
  "lint": "npm run ts-lint && npm run other-linters"
}

Note: The "lint" script will be called by CI then all linter scripts must be added.

TSCONFIG

Extend base configuration:

{
  "extends": "./node_modules/angular-configuration/tsconfig.json"
}

STYLELINT

Extend base configuration:

{
  "extends": "angular-configuration/stylelint"
}

Usage in package.json:

"scripts": {
  "lint-style": "stylelint \"src/**/*.(scss|html)\""
  "lint-style-fix": "stylelint \"src/**/*.(scss|html)\" --fix"
}

PRETTIER

Create .prettierrc.js file and use base configuration:

const baseConfig = require('angular-configuration/prettierrc');

module.exports = {
  ...baseConfig
};

Usage in package.json:

"scripts": {
  "prettier": "prettier --config .prettierrc.js --list-different \"src/**/*.ts\""
}

COMMITLINT

module.exports = {
  extends: [
    'angular-configuration/commitlint.config'
  ]
};

Usage in package.json:

"scripts": {
  "commitmsg": "commitlint -e $GIT_PARAMS"
}

Check Developmenmt enviroment

With this script you can ensure that everyone will use the exact same version of node and npm. (before an npm package install).

Copy the check-dev-env.js from the scripts folder into your project (into a scripts folder). Usage in package.json:

"scripts": {
  "preinstall": "node ./scripts/check-dev-env nodeVersion=8.11 npmVersion=6.4.1",
}

FAQs

Package last updated on 18 Jul 2020

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