# @atlassian/eslint-plugin-module-checks

> Rules to check various aspects of your AMD or ES6 modules for correctness.

Latest version **4.1.0** (published 2024-03-12) · SEE LICENSE IN LICENSE.txt license · 0 weekly downloads

## Install

```sh
npm install @atlassian/eslint-plugin-module-checks
pnpm add @atlassian/eslint-plugin-module-checks
yarn add @atlassian/eslint-plugin-module-checks
bun add @atlassian/eslint-plugin-module-checks
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 4.1.0 |
| Published | 2024-03-12 |
| First published | 2024-03-12 |
| Weekly downloads | 0 |
| License | SEE LICENSE IN LICENSE.txt |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=10 |
| Dependencies | 2 |
| Unpacked size | 29.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Atlassian Pty Ltd |
| Maintainers | kbielaski, dwalker, atlassian-aui, jvdl, mdejongh, mszczepanski, cdarroch, macku, dboyd, dmorrow, mstaas, cwhittington, doklovic, 1999-atlassian, amcculloch, wyasvoin, jmoynihan, xqiu, gleal-atlassian, mszpyra, bcytrowski, plai1, sraj, tilwin_atlassian, mrzymski, media-build-bot, akishore, timse, mkem114, tsebastian, sfp-release-bot |
| Keywords | eslint, eslintplugin |

## Links

- npm: https://www.npmjs.com/package/@atlassian/eslint-plugin-module-checks
- Repository: https://stash.atlassian.com/scm/fe/eslint-plugin-module-checks
- npm.io page: https://npm.io/package/@atlassian/eslint-plugin-module-checks

## Dependencies (2)

- [ast-traverse](https://npm.io/package/ast-traverse.md) ^0.1.1
- [eslint-plugin-requirejs](https://npm.io/package/eslint-plugin-requirejs.md) 4.0.1

## Alternatives

- [eslint-plugin-sonarjs](https://npm.io/package/eslint-plugin-sonarjs.md) — 2.9M weekly downloads
- [eslint-config-expo](https://npm.io/package/eslint-config-expo.md) — 1.5M weekly downloads
- [@matter/protocol](https://npm.io/package/@matter/protocol.md) — 63.5K weekly downloads
- [@eventcatalog/linter](https://npm.io/package/@eventcatalog/linter.md) — 24.8K weekly downloads
- [@pandacss/eslint-plugin](https://npm.io/package/@pandacss/eslint-plugin.md) — 18.7K weekly downloads

## Recent versions

- 4.1.0 (latest) — 2024-03-12
- 0.0.1-alpha (deprecated) — 2024-12-10

## README

# eslint-plugin-module-checks

Rules to check various aspects of your AMD or ES6 modules for correctness.

## Configuration

First include the plugin with `npm install @atlassian/eslint-plugin-module-checks`, then include it in your ESLint config

```json
{
    "plugins": [
        "@atlassian/module-checks"
    ],
    ...
}
```

Then enable the rules you want to use. For example:

Enable the rules that you would like to use, for example:

```json
{
    "rules": {
        "module-checks/no-unused-deps": 2,
        "module-checks/no-unordered-deps": 1
    }
}
```

## List of supported rules

-   [depend-on-require](docs/rules/depend-on-require.md): Allow or disallow use of the `require` module dependency
-   [named-define](docs/rules/named-define.md): Allow or disallow explicitly named modules
-   [no-unordered-deps](docs/rules/no-unordered-deps.md): Disallow unordered module dependencies
-   [no-unused-deps](docs/rules/no-unused-deps.md): Disallow dependencies that are not used in the module body

### List of borrowed rules

We borrow some rules from other ESLint plugins. They are listed below:

-   [no-assign-exports](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/no-assign-exports.md): Disallow assignment to `exports` when using Simplified CommonJS Wrapper
-   [no-conditional-require](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/no-conditional-require.md): Disallow use of conditional `require` calls (off by default)
-   [no-dynamic-require](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/no-dynamic-require.md): Disallow use of dynamically generated paths in a `require` call (off by default)
-   [no-invalid-define](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/no-invalid-define.md): Disallow invalid module definitions
-   [no-invalid-require](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/no-invalid-require.md): Disallow invalid `require` or `requirejs` calls
-   [no-js-extension](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/no-js-extension.md): Disallow `.js` extension in dependency paths
-   [no-require-tourl](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/no-require-tourl.md): Disallow use of `require.toUrl` and `require.nameToUrl` (off by default)
-   [one-dependency-per-line](https://github.com/cvisco/eslint-plugin-requirejs/tree/master/docs/rules/docs/rules/one-dependency-per-line.md): Enforce line-break rules for AMD dependencies (off by default)

---
_Source: https://npm.io/package/@atlassian/eslint-plugin-module-checks · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
