Skip to content
Esc

All rules

One row per rule, every package, generated from each plugin’s exported metadata. Each rule links to its page, which has the options it takes and the Incorrect and Correct examples that run in that package’s test suite. Filter the list below by name, package or description, by preset, or by what a rule can do. To jump straight to one rule from any page, open the search with Ctrl K (⌘ K on a Mac) or /. The same index is served as JSON at /eslint-plugins/rules.json for tools and agents; the shape is documented below.

rules
170
on in recommended
54
on in strict only
17
opt-in
52
lint-meta
47
autofix
6
suggestions
10

170 rules across 15 ESLint plugins and 1 lint-meta catalog. Of the 123 ESLint rules, 54 are switched on by a recommended preset, 17 more only by a strict preset (the house rules), 3 ship registered but off, and 49 are left out of every preset and enabled one by one. The 47 lint-meta rules run under @noctcore/harness, not ESLint. 2 rules read type information: noctcore-contracts/translation-key-exists (optional), noctcore-prisma/mutation-entry-must-reach-audit (required).

Showing 170 of 170

react18 rules · v1.1.0
noctcore-react/component-props-namingA function component's first-param props type must be named <Component>Props. Autofixes by renaming the in-file type declaration and its references when that is safe.strictautofix
noctcore-react/context-value-must-be-memoizedA context Provider value must not be an inline object, array or function: a fresh reference each render re-renders every consumer. Memoize it with useMemo / useCallback and pass the stable reference.error
noctcore-react/enforce-context-consumptionA prop whose value a registered scoped context already supplies must be read from the context, not declared or destructured as a prop again.not listedopt-in needs options
noctcore-react/max-hook-return-surfaceAn exported use* hook in a hook file may return object literals (top-level or nested one level) of at most max (default 20) members. Wider returns are god-controllers in the making.strict
noctcore-react/max-hooks-per-fileA hook/query/mutation file (default *.hooks.ts / *.queries.ts / *.mutations.ts) may export at most max (default 4) use* hooks. Split larger files.strict
noctcore-react/max-props-per-componentA *Props interface/type-literal may declare at most max (default 12) local members. extends clauses are not counted.strict
noctcore-react/max-state-per-hookA use* hook in a hook file may keep at most max (default 4) useState / useReducer slots, and a function inside it may call at most maxSettersPerFunction (default 3) distinct setters. Group the rest in a reducer.strict
noctcore-react/no-effect-derived-stateAn effect whose entire body is setState calls with values derived purely from its dependencies is the "you might not need an effect" anti-pattern — compute the value during render (or with useMemo) instead.error
noctcore-react/no-jsx-computationDisallow array methods, arithmetic, and chained logical expressions directly inside JSX {...}. Lift them to a const above the return or into the hook.strict
noctcore-react/no-jsx-in-hooksA use*-named function must not return JSX — that is a component wearing a hook costume. Rename it to a PascalCase component, or return values instead of elements.error
noctcore-react/no-native-date-inputDisallow native date inputs (type="date" and friends): Chromium formats them in the browser UI language and ignores lang, so the date order can contradict the page.not listedopt-in
noctcore-react/no-prop-drillingA bundle of maxForwarded+ (default 4) props each forwarded unchanged (name={name}) from the *Props param to the same child component is prop drilling. Compose instead.error
noctcore-react/no-state-in-component-bodyState/effect/query hooks must live in the colocated hook file (<Name>.hooks.ts), not in the component .tsx body. The component is a thin shell.strict
noctcore-react/no-unguarded-web-storageA localStorage / sessionStorage access must sit inside a try with a catch: the access itself throws when storage is disabled, partitioned or full.errorsuggestion
noctcore-react/password-input-requires-autocompleteA password field must carry an explicit autoComplete purpose, so a password manager can fill the current password and save a new one.error
noctcore-react/prefer-lazy-state-initA useState initializer that is an expensive call (default JSON.parse / localStorage.getItem / sessionStorage.getItem, or a configured builder) must be wrapped in a function so it runs once on mount, not every render.errorautofix
noctcore-react/props-must-be-visualComponent props must be visual. Auth/business-identity and credential prop names (userId, currentUser, *token*, *jwt*, *secret*, apiKey, ...) are disallowed. A live password input is a legitimate visual concern and is intentionally allowed.error
noctcore-react/require-effect-cancellationA setState/dispatch that runs after an await or .then() inside a useEffect must be guarded against a unmounted/re-run effect (AbortController, a cancelled flag, or a cleanup return).error
architecture10 rules · v1.1.0
noctcore-architecture/barrel-purityA barrel (an index.* file with an export … from re-export) must contain only re-exports, never local declarations, side effects, or default-exported values.strict
noctcore-architecture/colocated-test-requiredA source file matching an include glob must have a colocated *.test.* / *.spec.* sibling on disk.not listedopt-in needs options
noctcore-architecture/component-folder-structureA component <Name>/<Name>.tsx under <componentRoot>/<feature>/... must have its sibling set (.hooks.ts, .types.ts, .stories.tsx, .test.tsx, index.ts) present on disk.strict
noctcore-architecture/file-naming-patternIn a folder matched by folders, a file's basename must match pattern, a regular expression built from the folder's name.not listedopt-in needs options
noctcore-architecture/filename-matches-exportA file's basename must match its primary export (a default export, or the sole named export).strictsuggestion
noctcore-architecture/index-must-reexport-defaultA component folder's index.ts must re-export the component default (export { default as <Name> } from './<Name>').strict
noctcore-architecture/max-import-depthA relative import may not climb more than max parent levels (default 3). Autofixed to a path alias when one is configured.strictautofix
noctcore-architecture/no-cross-feature-importsA file in one feature may not import runtime code from another feature. Move shared code to a shared module or a shared feature.strict
noctcore-architecture/no-restricted-imports-layeredImport bans declared once as named sets and assigned to file layers, merged per file instead of overridden, covering static imports, re-exports and dynamic import().not listedopt-in needs options
noctcore-architecture/single-semantic-moduleRequire each module to export only one semantic concern (types, constants, functions, classes, components, hooks, schemas or enums).offopt-in
monorepo2 rules · v1.0.0
noctcore-monorepo/no-deep-package-importsWorkspace packages in the configured scopes must be consumed through their package barrel only — never via a deep subpath into package internals.not listedopt-in needs options
noctcore-monorepo/no-unexported-subpath-importImporting a @scope/pkg/<subpath> that the target workspace package's exports map does not expose. Reads the target package.json from disk.not listedopt-in needs options
contracts17 rules · v1.1.0
noctcore-contracts/describe-auth-matches-middlewareRequire the auth kind a route docs call declares to match the middleware in the same route chain, using a configured map from kind to middleware names.not listedopt-in needs options
noctcore-contracts/env-var-schema-parityRequire every process.env.FOO / import.meta.env.FOO key to be declared in a schema file (.env.example or a zod-env module), so config access and config declaration cannot drift apart.not listedopt-in needs options
noctcore-contracts/fetch-must-check-okRequire a fetch response to be checked with .ok or a status comparison before .json() parses its body.error
noctcore-contracts/money-must-be-decimalDisallow monetary values typed as the JS primitive number. Money-named fields explicitly typed : number lose precision to float rounding; use a Decimal money type instead.error
noctcore-contracts/no-direct-process-envDisallow direct process.env access. Force every consumer through a typed, validated config accessor so a missing variable fails at boot, not at use.error
noctcore-contracts/no-error-stringifyDisallow stringifying an error with bare ${error} interpolation, error.toString(), or error + "". These give "Error: <message>" or "[object Object]". Use error instanceof Error ? error.message : String(error) instead.errorsuggestion
noctcore-contracts/require-error-causeRequire re-thrown errors inside a catch to forward the caught error as { cause }. A throw new SomeError(...) that omits the cause severs the chain to the original failure.errorautofix suggestion
noctcore-contracts/require-registered-keysRequire the key/name argument of configured sink APIs (storage, event channels, cache keys) to be an imported constant from a registry module, not a raw string literal.not listedopt-in needs options
noctcore-contracts/require-schema-parse-at-boundaryDisallow asserting external boundary data with as T instead of parsing it at runtime. Flags casts of JSON.parse, res.json(), web storage, URL search params, message-event data and LLM tool input, directly or through a const; use a zod/valibot parse.offopt-in
noctcore-contracts/restrict-throw-to-taxonomyRestrict throw to an approved error taxonomy. Flags throwing a non-allowlisted error class and throwing a non-Error value (string, object, number, ...).not listedopt-in needs options
noctcore-contracts/route-handler-orderRequire the middleware arguments of a route method call to follow a configured group order (for example docs, auth, validation), with the handler last.not listedopt-in needs options
noctcore-contracts/route-params-validatedRequire a route whose path declares :name parameters to carry a param validator in its handler chain.not listedopt-in
noctcore-contracts/schema-enum-field-consistencyDisallow a zod field that is an enum in one object schema of a module from being z.string() in another, which widens the wire type every consumer then narrows by hand.error
noctcore-contracts/translation-key-existsRequire every static i18next / react-i18next translation key (t(...), i18n.t(...), <Trans i18nKey>) to exist in the catalog of the namespace in scope.not listedopt-in needs optionsoptional
noctcore-contracts/wire-message-namingA message-schema const ending in a role suffix (default Event/Command/Query) whose zod object declares type: z.literal(...) must set that literal to kebab-case(const name minus its role suffix).strictautofix
noctcore-contracts/zod-field-describeRequire every property of a zod object schema to carry a non-empty .describe() or .meta({ description }), so generated JSON Schema, tool definitions and API docs have text for each field.not listedopt-in
noctcore-contracts/zod-schema-namingEvery exported zod schema is a PascalCase const suffixed Schema, paired with a same-named inferred type (export type Foo = z.infer<typeof FooSchema>).strict
code-quality21 rules · v1.0.0
noctcore-code-quality/fake-timers-must-be-restoredA test file that calls useFakeTimers() must also call useRealTimers(), so fake timers do not leak into later tests.error
noctcore-code-quality/interface-prefix-iInterface names must be prefixed with I followed by an uppercase letter. Module/global augmentations are exempt.not listedopt-in
noctcore-code-quality/no-bare-date-nowDisallow bare Date.now() / new Date() in business logic. Read wall-clock time through a shared clock util (nowMs() / now()) so time is mockable.strict
noctcore-code-quality/no-conditional-expectDisallow expect() inside a branch, catch or loop that may not run: a skipped assertion lets a broken test pass.error
noctcore-code-quality/no-elided-code-commentsDisallow comments that stand in for elided code ('// ... existing code ...', '// rest of the function unchanged', '// your code here'). They are what an agent leaves when it rewrites a file from an abbreviated draft, and the code they replaced has usually been deleted.error
noctcore-code-quality/no-focused-testsBan focused tests (it.only / describe.only / test.only, fdescribe / fit / ddescribe) so a focused test never silently lands in CI.errorsuggestion
noctcore-code-quality/no-historical-commentsDisallow comments that frame code relative to what it used to do or to a past incident ('before the fix', 'after the refactor', 'we used to', 'no longer'). Source comments describe the current invariant; history belongs in the commit message or PR description, where it does not rot when the code changes again.error
noctcore-code-quality/no-message-only-throw-assertionDisallow toThrow() with no argument or with only a message: any error passes, including a TypeError from a broken mock. Pin the error class.not listedopt-in
noctcore-code-quality/no-narration-commentsDisallow narrative comments like 'Here we...', 'Now we...', 'First, we...'. These read as step-by-step prose and add no information a future reader cannot get from the code itself. Often a tell that the comment was generated by an agent describing its own changes.error
noctcore-code-quality/no-pr-reference-commentsDisallow PR/issue references in comments. They belong in commit messages and PR descriptions, where they do not rot when the repo moves, the issue tracker migrates, or the numbering changes.error
noctcore-code-quality/no-process-exitDisallow process.exit() outside bootstrap/shutdown paths and standalone CLIs. Application and service code must throw or reject so the lifecycle can shut down gracefully.error
noctcore-code-quality/no-real-clock-in-unit-testsUnit tests must not read the real clock (Date.now(), new Date()) unless the file fakes it; an offset from now (Date.now() + 60_000) is allowed.not listedopt-in
noctcore-code-quality/no-real-network-in-unit-testsUnit tests must not perform real network I/O: mock the HTTP client, or move the test to an integration suite.error
noctcore-code-quality/no-sleep-in-unit-testsUnit tests must not sleep on the real clock (new Promise((r) => setTimeout(r, n)), timers/promises): fake the timers or wait for the condition.not listedopt-in
noctcore-code-quality/no-swallowed-assertionDisallow assertions inside a try whose catch neither rethrows nor asserts, and .catch() handlers that swallow an expect(...).rejects/.resolves failure: the assertion fails, the error is dropped, and the test passes.error
noctcore-code-quality/no-template-trim-empty-ternaryDisallow inline <template>.trim() === '' ? fallback : <template>.trim() patterns. Extract to a named utility so the expression is built once and is unit-testable in one place.not listedopt-in
noctcore-code-quality/no-vacuous-expectDisallow vacuous expects (typeof checks, literal tautologies, a sole toBeDefined/toBeTruthy, a sole presence check on the render root): a test must assert behaviour that a real regression would break.error
noctcore-code-quality/prefer-early-returnPrefer guard clauses (early return) over wrapping the whole function body in a multi-statement if without an else.strict
noctcore-code-quality/prefer-web-first-page-assertionsDisallow asserting on a one-shot Playwright page read (expect(page.url()), expect(await page.title())): the check runs once, possibly before the navigation lands. Use the retrying toHaveURL / toHaveTitle.not listedopt-insuggestion
noctcore-code-quality/skipped-tests-need-trackingSkipped tests (.skip / .fixme / xit / xdescribe, and unconditional node:test { skip } / { todo } / t.skip()) must carry a tracking marker (an issue URL or TODO(@owner)) on or above the line, so the debt has an owner instead of rotting silently.errorsuggestion
noctcore-code-quality/typed-mock-over-double-castDisallow an object literal of jest.fn() / vi.fn() mocks cast as unknown as T: the double cast switches type checking off, so a mock of a renamed or removed method keeps passing.not listedopt-in
async-safety7 rules · v1.0.0
noctcore-async-safety/forward-abort-signalA function that accepts an AbortSignal (param named signal or typed AbortSignal) but awaits a call without ever forwarding it leaves that work uncancellable.error
noctcore-async-safety/no-concurrent-shared-mutationA read-modify-write of an outer-scope binding that awaits between the read and the write, inside a concurrent Promise.all(arr.map(async …)) callback, can lose updates.error
noctcore-async-safety/no-leaky-race-timeoutA setTimeout timeout raced with Promise.race must be cleared — otherwise the timer outlives the race whenever the other promise wins.error
noctcore-async-safety/no-shared-mutable-module-stateA module-scoped mutable binding written inside an exported async/handler function or an exported class method is shared across concurrent requests. Opt in per file via include.not listedopt-in needs options
noctcore-async-safety/prefer-parallel-awaitsConsecutive independent const x = await read() statements can run concurrently via await Promise.all([...]).offopt-insuggestion
noctcore-async-safety/require-client-timeoutA configured network client must be constructed with a timeout option; an unbounded client can hang forever.not listedopt-in needs options
noctcore-async-safety/require-fetch-timeoutA fetch (or configured wrapper) call must carry a signal/timeout in its options — an unbounded request can hang forever.errorsuggestion
observability4 rules · v1.0.0
noctcore-observability/audit-pii-declaredA PII-shaped key written into an audit payload must be declared, either registered for scrubbing on purge or declared non-PII.not listedopt-in needs options
noctcore-observability/no-error-detail-lossA catch block that reports a failure must not reduce the error to only e.message / String(e) / ${e} — log the error itself so its stack and cause survive.error
noctcore-observability/no-sensitive-fields-in-logsA logger call must not reference an identifier, property, or object key whose name matches a sensitive-field denylist (password, token, secret, ...). Redact it before logging.error
noctcore-observability/structured-log-argumentsA logger call must not interpolate dynamic values into the message string (a template literal with expressions). Pass a static message and a structured context object instead.error
security10 rules · v1.0.0
noctcore-security/auth-cookie-flagsAn auth cookie (session, sid, auth_token, authToken by default) must be written with httpOnly: true, secure and a valid sameSite.not listedopt-in
noctcore-security/bcrypt-rounds-minA bcrypt hash / hashSync / genSalt / genSaltSync call must not pass a literal cost below minRounds (default 10).not listedopt-in
noctcore-security/no-shell-interpolationA dynamically-interpolated command string must not flow into a shell runner (exec/execSync, or spawn/execFile with a shell option that is not false), including through promisify(exec). Pass the program and arguments separately.error
noctcore-security/no-timing-unsafe-compareAn HMAC digest or signature must not be compared with === / !== / == / != or Buffer#equals; use crypto.timingSafeEqual.error
noctcore-security/no-user-controlled-fetch-urlDisallow HTTP requests whose origin is not fixed at authoring time: a runtime-controlled host enables SSRF.error
noctcore-security/no-user-controlled-redirectDisallow redirects whose target origin is not fixed at authoring time: a user-controlled target is an open redirect.error
noctcore-security/presigned-post-requires-policyA createPresignedPost call must pin the upload size and Content-Type in literal Conditions.error
noctcore-security/require-path-containmentRequest-shaped input (req.*) passed directly into path.join / path.resolve without a containment test on the result is a path-traversal sink.not listedopt-in
noctcore-security/require-sanitized-htmlHTML reaching dangerouslySetInnerHTML, innerHTML, outerHTML or insertAdjacentHTML must be static markup or pass through a configured sanitizer.not listedopt-in
noctcore-security/server-action-through-clientIn a 'use server' module every exported action must be built from a configured action client; a raw exported function bypasses input validation, error shaping and middleware.not listedopt-in needs options
prisma12 rules · v1.0.0
noctcore-prisma/mutation-entry-must-reach-auditRequire a mutation entry point whose type-resolved call graph reaches a Prisma write to also reach an audit write. Reports only when the whole graph was read.not listedopt-inrequired
noctcore-prisma/no-audit-write-in-transactionDisallow an audit-log write inside a $transaction callback, where it rolls back with the business work. It does not check that mutations are audited at all.error
noctcore-prisma/no-cross-tenant-id-in-whereDisallow a Prisma query or write whose tenant id in where or data is read from client input. Without row-level security, a client-supplied tenant id is a cross-tenant access (IDOR).error
noctcore-prisma/no-raw-sql-outside-allowlistDisallow raw Prisma SQL ($queryRaw, $executeRaw, $queryRawTyped, *Unsafe) that can touch a table outside an allowlist. A raw query has no model, so a tenant-scope extension passes it through unscoped.error
noctcore-prisma/no-request-body-in-writeDisallow a Prisma write whose data (or where) is the raw request body. Passing client input straight through lets a caller set any column (mass assignment) or widen the filter.error
noctcore-prisma/no-unscoped-prisma-outside-allowlistDisallow the unscoped Prisma client and tenant-scope escape-hatch functions outside an allowlist of seeds, migrations, isolation tests, and designated system files.error
noctcore-prisma/prisma-tx-uses-tx-not-clientInside a $transaction(async (tx) => ...) callback, writes must go through the tx parameter, not the outer client, so they participate in the transaction and roll back together.error
noctcore-prisma/prisma-write-in-transactionDisallow two or more Prisma writes in a single function/method body that are not wrapped in a $transaction. A partial failure between writes leaves half-written state.error
noctcore-prisma/restrict-model-writesRestrict Prisma writes to configured models (or to configured columns of them) to the files that own those writes, including nested relation writes. It fences who writes; it does not validate which values or state transitions are legal.not listedopt-in needs options
noctcore-prisma/soft-deletable-tables-require-deleted-atRequire a filtered read or bulk write on a soft-deletable Prisma model to exclude soft-deleted rows in its where. Soft delete is convention only, with no Prisma extension injecting the filter, so a query that omits it reads and mutates deleted rows.not listedopt-in needs options
noctcore-prisma/tenant-scoped-tables-require-whereRequire every tenant field in the where of a read or bulk write on a tenant-scoped model through the unscoped client, and a scope column in the where of any query on a hand-scoped model.not listedopt-in needs options
noctcore-prisma/tenant-write-must-carry-tenant-idRequire every tenant field in the data of a create on a tenant-scoped Prisma model through the unscoped client, which does not inject the tenant scope.not listedopt-in needs options
rsc1 rule · v0.1.3
noctcore-rsc/no-navigation-throw-in-tryDisallow redirect(), notFound() and the other throwing next/navigation calls inside a try whose catch swallows the error instead of rethrowing it.error
llm1 rule · v0.1.3
noctcore-llm/no-llm-output-to-sinkText an LLM SDK call returned must not reach eval, a shell, raw SQL, HTML injection, a fetch origin or an fs path in the same function without being validated or sanitized first.error
nestjs9 rules · v0.2.0
noctcore-nestjs/job-name-must-be-constantRequire queue and job names passed to @Processor(...), @InjectQueue(...) and <queue>.add(...) to be shared constants, not inline string literals.not listedopt-in
noctcore-nestjs/job-options-must-set-attemptsRequire every BullMQ .add / .addBulk job to state attempts, and a backoff when it retries, in its options or its queue's defaultJobOptions.not listedopt-in
noctcore-nestjs/queue-add-requires-dedup-keyRequire every BullMQ .add / .addBulk job to carry a jobId or deduplication in literal options, so a producer retry cannot enqueue the same work twice.not listedopt-in
noctcore-nestjs/queue-options-must-set-retentionRequire every BullMQ .add job to state removeOnComplete and removeOnFail in its options or its queue's defaultJobOptions, so finished jobs do not pile up in Redis.not listedopt-in
noctcore-nestjs/redis-client-from-factoryRequire every Redis client and every inline BullMQ connection to take its options from a configured factory function, not from literal host, port or URL values.not listedopt-in needs options
noctcore-nestjs/schedule-states-time-zoneRequire a @Cron to state timeZone (or utcOffset) and a BullMQ cron schedule to state tz, so it does not run in whatever zone the host has.error
noctcore-nestjs/worker-concurrencyRequire a literal BullMQ worker concurrency, on new Worker(...) or @Processor(queue, options), to be a positive integer, and with requireExplicit require it to be stated.not listedopt-in
noctcore-nestjs/worker-must-implement-closeRequire a class that creates a BullMQ Worker in a field to call .close() on it in a shutdown method such as onModuleDestroy, so in-flight jobs are not abandoned.error
noctcore-nestjs/worker-must-listen-failedRequire every BullMQ new Worker(...) to have a .on('failed', ...) listener in the same file, so a failing job is not silent.error
query6 rules · v0.2.0
noctcore-query/effect-fired-mutation-must-bind-callbacksRequire a mutation fired from an effect to carry its onSuccess/onError on useMutation, not as per-call mutate() options, which a detached observer never delivers.error
noctcore-query/mutation-requires-error-handlingRequire a TanStack Query mutation to handle its error somewhere visible: onError on the hook, onError or a catch at the call, or a read of its error state.not listedopt-in
noctcore-query/prefix-query-key-must-use-set-queries-dataReport setQueryData(PREFIX, ...) and getQueryData(PREFIX) when the file builds its query keys as [...PREFIX, id]: the exact-key call misses every entry, and setQueriesData / getQueriesData match the prefix.not listedopt-insuggestion
noctcore-query/query-fn-must-not-swallow-errorDisallow a queryFn that catches its error and returns a fallback value, which turns a failed request into cached data the query reports as a success.not listedopt-in
noctcore-query/query-key-must-be-constantRequire query and mutation keys to come from a constant or key factory, not an inline array that starts with a string.not listedopt-in
noctcore-query/trpc-invalidate-with-path-keyRequire pathKey() when a tRPC procedure is invalidated, refetched, cancelled, removed or reset without an input. A bare queryKey() misses infinite queries.errorautofix
electron3 rules · v0.1.0
noctcore-electron/ipc-handler-validates-senderRequire every inline ipcMain.handle / ipcMain.on handler to check its sender (event.senderFrame) in its first statement, before it does anything else.not listedopt-in
noctcore-electron/no-shell-outside-allowlistRestrict Electron's shell (openExternal, openPath) to the files listed in allowIn, so URLs and paths reach the operating system through one checked module.not listedopt-in needs options
noctcore-electron/webpreferences-lockedDisallow turning off an Electron renderer isolation flag: nodeIntegration, webviewTag or allowRunningInsecureContent set to true, or contextIsolation, sandbox or webSecurity set to false.error
dates2 rules · v0.1.0
noctcore-dates/calendar-math-via-sharedDisallow hand-rolled calendar arithmetic (getUTC* / setUTC*, Date.UTC(), setMonth, and milliseconds-per-day constants) outside the calendar module listed in allowIn.not listedopt-in
noctcore-dates/no-local-calendar-timeDisallow reading a calendar day through the machine's time zone: local Date accessors, new Date('YYYY-MM-DD'), and toISOString().slice(0, 10).not listedopt-in
lint-meta-rules47 rules · v1.1.0 · whole-repo checks
lint-meta-rules/agents-doc-presenceAGENTS.md must exist at the repo root, every surface, and every non-opted-out package.harness
lint-meta-rules/banned-dependenciesWorkspace manifests must not declare a banned dependency.harness
lint-meta-rules/canonical-helpers-single-homePure helpers must live in one canonical home (flag the same exported symbol appearing in multiple homes).harness
lint-meta-rules/dockerfile-base-image-digest-pinDockerfile FROM base images must be pinned by @sha256: digest (scratch and earlier build stages exempt).harness
lint-meta-rules/eslint-config-no-warnEvery rule in the RESOLVED ESLint config is "error" or "off", never "warn", including severities a spread preset injects.harness
lint-meta-rules/eslint-override-paths-existPaths written in an ESLint flat config files or ignores entry (and the directory a files glob starts in) must exist, so a moved folder cannot leave an override that applies to nothing.harness
lint-meta-rules/eslint-rules-not-weakenedEvery pinned ESLint rule holds at least its pinned severity and options in the RESOLVED config, so a spread preset or a later override cannot weaken it.harness
lint-meta-rules/file-size-ratchetSource files stay at or under 400 raw lines. Today's offenders are grandfathered by .nightcore/lint-meta/baselines/file-size-ratchet.json; a new/grown offender fails, and a stale/shrunk baseline entry demands tightening.harness
lint-meta-rules/github-actions-concurrency-explicitA workflow-level or job-level concurrency mapping must state cancel-in-progress; the string form passes unless requireMappingForm is set.harness
lint-meta-rules/github-actions-expression-syntaxGitHub Actions workflows never hold a malformed ${{ (an opener followed by another {, or one with no closing }}), which fails the whole workflow before any job runs.harness
lint-meta-rules/github-actions-least-privilege-permissionsGitHub Actions workflows declare a read-only top-level permissions: (no write-all/read-all, no <scope>: write); writes go on the job that needs them.harness
lint-meta-rules/github-actions-no-template-injectionGitHub Actions run: and github-script bodies never expand attacker-controllable ${{ }} context (issue/PR titles, comments, branch names); pass it through env: instead.harness
lint-meta-rules/github-actions-paths-filter-permissionsA job that runs a paths-filter action must have an effective pull-requests: read grant; a job-level permissions: block replaces the workflow-level one.harness
lint-meta-rules/github-actions-pip-install-pinnedPackages installed with pip, uv pip or pipx in a GitHub Actions run step must be pinned to an exact version with ==.harness
lint-meta-rules/github-actions-runner-pinnedGitHub Actions jobs must run on a pinned runner image (for example ubuntu-24.04), never a *-latest label.harness
lint-meta-rules/github-actions-security-no-cancelSecurity scan workflows (file name matching securityWorkflowPattern) never set a literal cancel-in-progress: true in a workflow-level or job-level concurrency, so a newer run cannot cancel a scan halfway.harness
lint-meta-rules/github-actions-self-hosted-fork-guardA GitHub Actions job triggered by pull_request must not run on a self-hosted runner unless runs-on carries a fork guard.harness
lint-meta-rules/github-actions-sha-pinnedGitHub Actions uses: refs must be pinned to a 40-character commit SHA with a # vN comment (local ./ actions exempt).harness
lint-meta-rules/github-actions-timeout-requiredGitHub Actions jobs must declare a job-level timeout-minutes (reusable-workflow calls are exempt).harness
lint-meta-rules/idempotency-key-parityProcedures carrying the idempotency middleware must have a client caller that sends an idempotency key, or no client caller at all.harness
lint-meta-rules/layer-rankFixed dependency direction by rank: a module imports only strictly-lower-ranked <scope> packages (equal/upward forbidden).harness
lint-meta-rules/no-cloned-component-foldersA component folder name may exist under only ONE feature. Shared surfaces are hoisted; divergent ones get a divergent name. Today’s clones are frozen in a shrinking allowlist.harness
lint-meta-rules/no-inline-lint-disableHand-written source must not carry inline eslint-disable directives; a deliberate exception belongs in a scoped config override.harness
lint-meta-rules/no-ts-ignoreHand-written source must not suppress TypeScript errors with @ts-ignore (or @ts-expect-error unless allowed).harness
lint-meta-rules/no-warn-severityESLint severity is 'error' or 'off', never 'warn'. A rule that matters is an error; a failure is fixed, not silenced.harness
lint-meta-rules/noctcore-packages-currentAn installed @noctcore package must match the range that declares it (and, with checkRegistry, that range must reach the latest published version), so a caret on 0.x cannot silently pin the repo behind a published minor.harness
lint-meta-rules/node-version-parity.nvmrc, the root engines.node floor, every setup-node step and every Docker node base image agree on the Node major.harness
lint-meta-rules/package-shapeEvery workspace is named <scope>/<dir>; library packages expose a barrel and point main/module/types/exports at the built output.harness
lint-meta-rules/pnpm-hardening-settingspnpm-workspace.yaml keeps the install hardening on (strictDepBuilds, blockExoticSubdeps, engineStrict, trustPolicy: no-downgrade, a minimum release age), every trustPolicyExclude entry exact and reasoned, and no governed setting is overridden in .npmrc, package.json or on a command line.harness
lint-meta-rules/pnpm-override-ledgerEvery pnpm override needs an entry in overrides.ledger.json with a reason and a reviewBy that has not passed, a security pin must target its own firstPatched or higher, and the lockfile must honour the override.harness
lint-meta-rules/prisma-method-surfaceThe Prisma reads and writes the rules police partition the generated client's <Model>Delegate method surface exactly, so a Prisma upgrade cannot add an unguarded method.harness
lint-meta-rules/security-scanner-version-parityThe gitleaks version pinned in the workflows must equal the one in scripts/ci/pre-push.sh, and the hook must compare a native gitleaks against it at run time.harness
lint-meta-rules/service-image-digest-pinWorkflow service and container images, and docker-compose images, must be pinned by @sha256: digest (a service that builds locally is exempt).harness
lint-meta-rules/session-epoch-capturedEvery call into the sign-in seam must pass the session epoch captured before the credential was read, or a revocation landing during the credential check loses the race.harness
lint-meta-rules/session-kind-stampedEvery call that mints a session must stamp the principal kind onto it, or sit in an allowlisted, provably single-kind flow; a session read without the kind falls back to a default and can silently promote one kind of account into another.harness
lint-meta-rules/session-landing-declaredEvery file that opens a door into a session must declare where it leaves the caller, and a door whose landing demands a return shape (the one that carries the principal kind to the client) must have it.harness
lint-meta-rules/session-mint-callersThe method that mints a session may only be called from allowlisted files; a new sign-in entry point must route through the gate in front of it so the gate cannot be bypassed.harness
lint-meta-rules/tenant-model-registry-parityEvery tenant-bearing Prisma model is scoped by the runtime extension or exempt with a reason, and the tenant lint rules resolve with exactly that registry.harness
lint-meta-rules/test-file-matches-runner-includeEvery test file must match the include patterns of a test runner that covers its directory, so a test that never runs cannot pass as coverage.harness
lint-meta-rules/test-files-require-source-siblingEvery colocated test file must sit next to the source it covers: a same-named source file, or a directory module's index.harness
lint-meta-rules/test-runner-segregationBun-side packages use 'bun:test'; foreign-side packages use 'vitest'. Never mix runners.harness
lint-meta-rules/test-sibling-enforcementEvery source file matched by include must have a colocated sibling test. Pure helpers must ship a test.harness
lint-meta-rules/test-workspace-enrollmentEvery candidate package with test files must be enumerated in the root 'test:node' script.harness
lint-meta-rules/translation-dead-keysEvery translation catalog key must be reachable from the source: named by a translation call, or spelled by some string in the code.harness
lint-meta-rules/tsconfig-include-paths-existEvery literal path in a tsconfig include or files (and the directory a glob entry starts in) must exist, so a renamed folder cannot drop out of type checking in silence.harness
lint-meta-rules/ui-primitive-shapeA folder primitive under the ui root must ship its proof siblings (test, stories); a flat primitive must not carry sibling proof files at the root.harness
lint-meta-rules/workspace-graph-parityImported <scope>/* specifiers must be declared workspace:* deps, and tsconfig references must mirror those deps.harness

Preset: the rule's severity in its package's configs.recommended. strict is on only in configs.strict, the package'srecommended plus its house rules. error is on. off (registered, switched off) and not listed (left out) are both opt-in: you turn the rule on yourself. needs options means it does nothing until you configure it. harness marks a lint-meta rule, which has no ESLint preset. deprecated marks a rule that still works but is in no preset and will be removed; move to the rule named after it. Fix:autofix with --fix,suggestion in your editor. Types: whether the rule needs a type-checked program (parserOptions.projectService), or uses one when present.

rules.json is generated at build time from the same catalog as the table above, so it cannot disagree with it. llms.txt at the site root points here and at it. The shape is a public contract: fields are added, never renamed or removed, without a schemaVersion bump. A build check asserts the file has exactly one entry per rule doc and that every url resolves to a page on this site.

Top level:

Field Meaning
schemaVersion Integer, currently 1. Bumped only on a breaking change to this shape.
generatedAt ISO timestamp of the build that emitted the file.
site The site root URL.
rulesPage URL of this page.
count Number of entries in rules.
packages One entry per package: name (npm), short, version, description, kind, namespace, url.
rules One entry per rule, in package order then by name.

Each entry in rules:

Field Meaning
id The id a config or a report uses: noctcore-react/no-prop-drilling, or the bare lint-meta id.
name The rule name without its namespace.
package npm name of the package that exports it.
runner eslint, or harness for a lint-meta rule that runs under @noctcore/harness.
description The rule’s meta.docs.description.
url The rule’s page on this site, the same URL as its meta.docs.url.
recommended error or off in the package’s recommended preset; null when the preset leaves it out, and for lint-meta rules.
strict error or off in the package’s strict preset (recommended plus the house rules); null when the package has no strict preset, the preset leaves it out, and for lint-meta rules.
fixable Whether the rule has an autofix.
hasSuggestions Whether the rule offers suggestions.
typeInfo required, optional or none: whether the rule needs a type-checked program.
deprecated Whether the rule is deprecated. A deprecated rule still works, but no preset enables it.
replacedBy Ids of the rules to use instead of a deprecated one; empty when there is none.
deprecatedSince The package version that deprecated the rule, or null.
category, ciCritical, factory, entry lint-meta rules only: the harness category, whether a violation fails CI by default, the factory export and the entry point that exposes it.