knip 6.1.0 → 6.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -132,7 +132,7 @@ export const resolveConfig = async (localConfig, options) => {
132
132
  for (const entry of await getIndexHtmlEntries(viteRoot))
133
133
  inputs.add(entry);
134
134
  }
135
- const dir = join(options.cwd, cfg.test?.root ?? '.');
135
+ const dir = toAbsolute(cfg.test?.root ?? '.', options.cwd);
136
136
  if (cfg.test) {
137
137
  if (cfg.test?.include) {
138
138
  for (const dependency of cfg.test.include)
@@ -11,7 +11,7 @@ import { walkAST } from "./visitors/walk.js";
11
11
  const jsDocImportRe = /import\(\s*['"]([^'"]+)['"]\s*\)(?:\.(\w+))?/g;
12
12
  const jsDocImportTagRe = /@import\s+(?:\{[^}]*\}|\*\s+as\s+\w+)\s+from\s+['"]([^'"]+)['"]/g;
13
13
  const jsxImportSourceRe = /@jsxImportSource\s+(\S+)/;
14
- const referenceTypesRe = /\s*<reference\s+types\s*=\s*"([^"]+)"\s*\/>/;
14
+ const referenceTypesRe = /\s*<reference\s+types\s*=\s*"([^"]+)"[^/]*\/>/;
15
15
  const envRe = /@(?:vitest|jest)-environment\s+(\S+)/g;
16
16
  const getImportsAndExports = (filePath, sourceText, resolveModule, options, ignoreExportsUsedInFile, skipExportsForFile, visitor, pluginCtx, cachedParseResult) => {
17
17
  const skipExports = skipExportsForFile || !options.isReportExports;
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const version = "6.1.0";
1
+ export declare const version = "6.1.1";
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const version = '6.1.0';
1
+ export const version = '6.1.1';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "knip",
3
- "version": "6.1.0",
3
+ "version": "6.1.1",
4
4
  "description": "Find and fix unused dependencies, exports and files in your TypeScript and JavaScript projects",
5
5
  "keywords": [
6
6
  "analysis",