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

eslint-config-cloudinsight

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-config-cloudinsight

eslint config use by cloudinsight

  • 1.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4
Maintainers
1
Weekly downloads
 
Created
Source

eslint-config-cloudinsight

这是 CloudInsight 用到的基于 Airbnb 的 eslint 配置,它能够很好的统一前端的编码风格。

新手指南

安装 eslint 和相关的模块

npm install eslint-config-cloudinsight@1 eslint@2 babel-eslint@6 eslint-config-airbnb@6 eslint-plugin-react@4 --save-dev

在项目目录下新建 .eslintrc.json 这是 eslint 的默认配置文件

{
  "extends": "cloudinsight"
}

在项目 package.json 的 scripts 新加一项

{
  "scripts":{
    "eslint":"eslint --ext=js,es6,jsx ./src"
  }
  ...
}

运行 eslint 检查

npm run-script eslint

加到你的 CI 环境里

node_modules/.bin/eslint --ext es6,jsx,js --format checkstyle -o checkstyle.xml ./src || true

截图

参考资料

http://eslint.org/docs/developer-guide/shareable-configs

Keywords

FAQs

Package last updated on 25 Apr 2016

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