Registry / devops / ko-lints

ko-lints

JSON →
library4.0.22jsnpmunverified

ko-lint provides linting tools (ESLint, Prettier) for the DTStack/ko ecosystem. Current stable version is 4.0.22. It is a wrapper that enforces consistent lint configurations across ko projects. Key differentiator: tightly integrated with ko-script build system; ships TypeScript types. Release cadence is tied to ko releases. Transitive peer dependency on ko-lint-config.

npm install ko-lints
INSTALL
IMPORT
SIG · KO-LINTS
K
ko-lints
devopsjavascriptv4.0.22
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

lint
import { lint } from 'ko-lints'
const lint = require('ko-lints')
ESM-only package; CJS require will not work.
format
import { format } from 'ko-lints'
Named export, no default export.
default
import koLint from 'ko-lints'
import { default } from 'ko-lints'
Default export is deprecated; use named exports.

Shows how to import and use lint and format functions.

import { lint, format } from 'ko-lints'; const files = ['src/**/*.ts']; const lintResults = lint(files); console.log('Lint issues:', lintResults); format(files, { fix: true });
Debug
Known issues
breakingko-lints v4 is ESM-only; CJS require fails.
fix
Use ESM imports (import { lint } from 'ko-lints') or upgrade to Node >=14.
affects: >=4.0.0
deprecatedDefault export deprecated since v3, removed in v4.
fix
Use named exports.
affects: >=4.0.0
gotchako-lint-config peer dependency must be manually installed.
fix
npm install ko-lint-config
affects: >=2.0.0
Errors
Common errors & fixes
Error [ERR_REQUIRE_ESM]: require() of ES Module /path/node_modules/ko-lints/index.mjs not supported.
CJS require used on ESM-only package.
fix
Change require() to import or upgrade Node.
Module not found: Can't resolve 'ko-lint-config'
Missing peer dependency ko-lint-config.
fix
npm install ko-lint-config
TypeError: koLint is not a function
Using deprecated default import that no longer exports a function.
fix
Use named exports like lint, format.
Upgrade
Version history
4.0.22latest on npm
Audit
Dependencies
ko-lint-configrequiredpeer dependency required for configuration
Agent activity
6 hits · last 30 days
node
6
Resources
ko-lints — npm install ko-lints · libregistry