🚀 DAY 5 OF LAUNCH WEEK: Introducing Socket Firewall Enterprise.Learn more →
Socket
Book a DemoInstallSign in
Socket

@tiendeo/content-lint

Package Overview
Dependencies
Maintainers
6
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tiendeo/content-lint

eslint, prettier & stylelint configurations

latest
npmnpm
Version
1.1.1
Version published
Maintainers
6
Created
Source

tiendeo-lint

​

Installation

​

  • Install @tiendeo/content-lintpackage:
npm i -D @tiendeo/content-lint

​ 2. Add these lines to package.json: ​

"eslintConfig": {
   "extends": ["./node_modules/@tiendeo/content-lint/.eslintrc.js"]
 },
 "stylelint": {
   "extends": "./node_modules/@tiendeo/content-lint/stylelint.config.js"
 },

​

Usage

​

  • Add these scripts to the package.json: ​
"eslint": "./node_modules/.bin/eslint \"src/**/*.{js,jsx}\"",
"stylelint": "./node_modules/.bin/stylelint \"src/**/*.{js,jsx}\"",
"format": "npm run prettier -- --write",
"prettier": "./node_modules/.bin/prettier \"src/**/*.{js,jsx,css,json}\" --config ./node_modules/@tiendeo/content-lint/.prettierrc.js"

Optional: If your project don't use Webpack, you may encounter conflicts with some routes, there is a script to fix that, also in package.json:

"removeWebpackLint": "node ./node_modules/@tiendeo/content-lint/scripts/removeWebpackLint.js"

​

Lint JS files

​

$ npm run eslint [options]

​

Fix JS files

​

$ npm run eslint -- --fix [options]

​

Format JS files

​

$ npm run format [options]

​

Lint Styled-Components

​

$ npm run stylelint [options]

​

Fix Styled-Components

​

$ npm run stylelint -- --fix [options]

FAQs

Package last updated on 13 Jan 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