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

learning-tslint

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

learning-tslint

Just one of the things I'm learning. <https://github.com/hchiam/learning>

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

Learning TSLint

Just one of the things I'm learning. https://github.com/hchiam/learning

Followed this tutorial: https://blog.bitsrc.io/extending-tslint-to-add-custom-rules-b30ca96158ee?gi=31845781f87c

Another example for reference: https://github.com/JKillian/tslint-custom-rule-example/blob/master/src/noNumberPremadeRule.ts

From scratch

npm init -y
npm install typescript tslint tsutils jest ts-jest @types/jest @types/node

And then:

touch index.js # and add in code to refer to files inside /rulesDirectory
mkdir rulesDirectory
cd rulesDirectory
touch classNamePascalCaseRule.ts
tsc classNamePascalCaseRule.ts

And finally:

npm publish

Starting by testing out this repo

Triple-click the following to select all:

git clone https://github.com/hchiam/learning-tslint.git; cd learning-tslint; npm install; # and then ...

Notes

  • Rule identifier ruleName: kebab-case, and correspond to rule file name (minus "Rule" at the end).
  • Rule file name: camelCase, end name with "Rule".
  • Exported class: just named Rule.
  • Exported class: extends Lint.Rules.AbstractRule.

FAQs

Package last updated on 26 Oct 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