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

metalint

Package Overview
Dependencies
Maintainers
1
Versions
40
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metalint

One linter to rule them all.

latest
Source
npmnpm
Version
0.21.2
Version published
Weekly downloads
101
-47.94%
Maintainers
1
Weekly downloads
 
Created
Source

Metalint

npm build coverage semver

One linter to rule them all.

Metalint is a tool for analyzing all the files in your project. Analysis is delegated to linters (static source code analysis tools):

Language / TechnologyLinters
CoffeeScript CoffeeLint
CSS Biome, DoIUse, Prettier, PurgeCSS, Stylelint
HTML HTMLHint, htmllint, markuplint, Prettier
JavaScript Biome, ESLint, JSHint, JavaScript Standard Style, Prettier
JSON Ajv, Biome, @mapbox/JSON Lint lines-primitives, @prantlf/JSON Lint, JSON Lint (mod), Prettier
Less Prettier, Stylelint
Markdown MarkdownLint
package.json Depcheck, npm-check-updates, npm-package-json-lint, publint, Sort Package.json
SCSS Prettier, Stylelint
SugarSS Stylelint
SVG Prettier, SVGLint
WebExtension Add-ons Linter
YAML YAML Lint, Prettier
Secretlint

Install

You can install Metalint using npm:

npm install --save-dev metalint

Configuration

All configuration files are grouped together in the .metalint/ directory, which should be placed at the root of the project. The metalint.config.js file exports a JSON object indicating the linters to be used for each file. The other files contain the specific options for the linters.

Example

In this example of configuration files, Metalint analyzes JavaScript (non-minified), HTML and CSS files; with ESLint, HTMLHint and Stylelint linters respectively.

// .metalint/metalint.config.js
export default {
  patterns: ["**", "!/.git/**", "!/node_modules/**"],
  checkers: [
    {
      patterns: ["*.js", "!*.min.js"],
      linters: "eslint",
    },
    {
      patterns: "*.html",
      linters: "htmlhint",
    },
    {
      patterns: "*.css",
      linters: "stylelint",
    },
  ],
};
// .metalint/eslint.config.js
export default {
  rules: {
    quotes: ["error", "double"],
    semi: ["error", "always"],
  },
};
// .metalint/htmlhint.config.js
export default {
  "attr-value-not-empty": false,
};
// .metalint/stylelint.config.js
export default {
  rules: {
    "color-no-invalid-hex": true,
  },
};

If you want to see real configurations, you've got the Metalint configuration itself; or the Cast Kodi configuration (a browser WebExtension developed in JavaScript, HTML, CSS).

Integration

npm

After installing Metalint and the linters in your npm project, you can add the following script to your package.json:

{
  "scripts": {
    "lint": "metalint",
    "lint:fix": "metalint --fix"
  }
}

Metalint can now be used with the following commands: npm run lint and npm run lint:fix.

GitHub Actions

To launch Metalint in your GitHub Actions, you can use the github formatter to report problems in pull requests.

jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
        with:
          persist-credentials: false
      - uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
      - name: Install dependencies
        run: npm ci
      - name: Lint files
        run: npm run lint -- --formatter github

Keywords

checker

FAQs

Package last updated on 01 Jan 2026

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