Socket
Socket
Sign inDemoInstall

eslint-config-ts-mailonline

Package Overview
Dependencies
9
Maintainers
3
Versions
15
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    eslint-config-ts-mailonline

ESLint TS config for MailOnline


Version published
Weekly downloads
261
decreased by-8.74%
Maintainers
3
Created
Weekly downloads
 

Readme

Source

eslint-config-ts-mailonline

NPM version Build status

MailOnline ESlint Typescript configuration.

Usage

  1. Add eslint-config-ts-mailonline, eslint, typescript, prettier, husky, and pretty-quick as development dependencies:
yarn add --dev eslint-config-ts-mailonline eslint typescript prettier husky pretty-quick
  1. Create a tsconfig.eslint.json file (this is a technicality due to the way the eslint typescript parser works):
{
  "compilerOptions": {"strict": true},
  "include": ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx"],
  "exclude": ["node_modules", "dist", "coverage"]
}
  1. Create ESLint configuration file (.eslintrc.json) that extends ts-mailonline:
{
  "extends": ["ts-mailonline", "ts-mailonline/react"],
  "parserOptions": {
    "project": "./tsconfig.eslint.json"
  }
}
  1. Create prettier.config.js on the root of your project with these contents:
module.exports = require('eslint-config-ts-mailonline/prettier');
  1. Create an .eslintignore file:
bin/
dist/
coverage/
dev/
node_modules/
*.css.d.ts
  1. Add the following script command to your package.json:
{
  "lint": "tsc --noEmit && eslint './**/*.{js,jsx,ts,tsx}'"
}
  1. Add the following pre-commit hook to your husky pre-commit script:
pretty-quick --staged && yarn run lint

Breaking changes

Any changes to this package that might cause code using it to not validate anymore, will be a semver-major change.

Keywords

FAQs

Last updated on 24 Jan 2024

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc