knip 5.87.0 → 5.88.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.
@@ -486,6 +486,11 @@ export declare class ConfigurationChief {
486
486
  entry?: string | string[] | undefined;
487
487
  project?: string | string[] | undefined;
488
488
  } | undefined;
489
+ raycast?: string | boolean | string[] | {
490
+ config?: string | string[] | undefined;
491
+ entry?: string | string[] | undefined;
492
+ project?: string | string[] | undefined;
493
+ } | undefined;
489
494
  'react-cosmos'?: string | boolean | string[] | {
490
495
  config?: string | string[] | undefined;
491
496
  entry?: string | string[] | undefined;
@@ -546,6 +551,11 @@ export declare class ConfigurationChief {
546
551
  entry?: string | string[] | undefined;
547
552
  project?: string | string[] | undefined;
548
553
  } | undefined;
554
+ sanity?: string | boolean | string[] | {
555
+ config?: string | string[] | undefined;
556
+ entry?: string | string[] | undefined;
557
+ project?: string | string[] | undefined;
558
+ } | undefined;
549
559
  'semantic-release'?: string | boolean | string[] | {
550
560
  config?: string | string[] | undefined;
551
561
  entry?: string | string[] | undefined;
@@ -856,6 +866,7 @@ export declare class ConfigurationChief {
856
866
  prettier?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
857
867
  prisma?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
858
868
  qwik?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
869
+ raycast?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
859
870
  "react-cosmos"?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
860
871
  "react-native"?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
861
872
  "react-router"?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
@@ -868,6 +879,7 @@ export declare class ConfigurationChief {
868
879
  rslib?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
869
880
  rspack?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
870
881
  rstest?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
882
+ sanity?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
871
883
  "semantic-release"?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
872
884
  sentry?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
873
885
  "simple-git-hooks"?: (boolean | import("./types/config.ts").EnsuredPluginConfiguration) | undefined;
@@ -224,11 +224,13 @@ export class DependencyDeputy {
224
224
  const position = peeker.getLocation('dependencies', symbol);
225
225
  dependencyIssues.push({ type: 'dependencies', workspace, filePath, symbol, fixes: [], ...position });
226
226
  }
227
- for (const symbol of this.getDevDependencies(workspace).filter(isNotReferencedDependency)) {
227
+ const manifest = this._manifests.get(workspace);
228
+ for (const symbol of this.getDevDependencies(workspace)) {
229
+ if (!manifest.dependencies.includes(symbol) && !isNotReferencedDependency(symbol))
230
+ continue;
228
231
  const position = peeker.getLocation('devDependencies', symbol);
229
232
  devDependencyIssues.push({ type: 'devDependencies', filePath, workspace, symbol, fixes: [], ...position });
230
233
  }
231
- const manifest = this._manifests.get(workspace);
232
234
  for (const symbol of this.getOptionalPeerDependencies(workspace)) {
233
235
  if (!isReferencedDependency(symbol))
234
236
  continue;
@@ -256,6 +258,11 @@ export class DependencyDeputy {
256
258
  if (!packageName)
257
259
  continue;
258
260
  if (IGNORED_DEPENDENCIES.has(packageName)) {
261
+ if (type === 'devDependencies') {
262
+ const manifest = this.getWorkspaceManifest(issue.workspace);
263
+ if (manifest?.dependencies.includes(packageName))
264
+ continue;
265
+ }
259
266
  delete issueSet[issueKey];
260
267
  counters[type]--;
261
268
  }
@@ -12,10 +12,11 @@ export const fix = async (issues, counters, options) => {
12
12
  const group = issues[type];
13
13
  if (group instanceof Set)
14
14
  continue;
15
+ const counterType = (type === '_files' ? 'files' : type);
15
16
  for (const filePath in group)
16
17
  for (const key in group[filePath])
17
18
  if (group[filePath][key].isFixed)
18
- counters[type]--;
19
+ counters[counterType]--;
19
20
  }
20
21
  if (options.isFormat) {
21
22
  const report = await formatly(Array.from(touchedFiles));
@@ -435,6 +435,11 @@ export declare const partitionCompilers: (rawLocalConfig: RawConfiguration) => {
435
435
  entry?: string | string[] | undefined;
436
436
  project?: string | string[] | undefined;
437
437
  } | undefined;
438
+ raycast?: string | boolean | string[] | {
439
+ config?: string | string[] | undefined;
440
+ entry?: string | string[] | undefined;
441
+ project?: string | string[] | undefined;
442
+ } | undefined;
438
443
  'react-cosmos'?: string | boolean | string[] | {
439
444
  config?: string | string[] | undefined;
440
445
  entry?: string | string[] | undefined;
@@ -495,6 +500,11 @@ export declare const partitionCompilers: (rawLocalConfig: RawConfiguration) => {
495
500
  entry?: string | string[] | undefined;
496
501
  project?: string | string[] | undefined;
497
502
  } | undefined;
503
+ sanity?: string | boolean | string[] | {
504
+ config?: string | string[] | undefined;
505
+ entry?: string | string[] | undefined;
506
+ project?: string | string[] | undefined;
507
+ } | undefined;
498
508
  'semantic-release'?: string | boolean | string[] | {
499
509
  config?: string | string[] | undefined;
500
510
  entry?: string | string[] | undefined;
@@ -1131,6 +1141,11 @@ export declare const partitionCompilers: (rawLocalConfig: RawConfiguration) => {
1131
1141
  entry?: string | string[] | undefined;
1132
1142
  project?: string | string[] | undefined;
1133
1143
  } | undefined;
1144
+ raycast?: string | boolean | string[] | {
1145
+ config?: string | string[] | undefined;
1146
+ entry?: string | string[] | undefined;
1147
+ project?: string | string[] | undefined;
1148
+ } | undefined;
1134
1149
  'react-cosmos'?: string | boolean | string[] | {
1135
1150
  config?: string | string[] | undefined;
1136
1151
  entry?: string | string[] | undefined;
@@ -1191,6 +1206,11 @@ export declare const partitionCompilers: (rawLocalConfig: RawConfiguration) => {
1191
1206
  entry?: string | string[] | undefined;
1192
1207
  project?: string | string[] | undefined;
1193
1208
  } | undefined;
1209
+ sanity?: string | boolean | string[] | {
1210
+ config?: string | string[] | undefined;
1211
+ entry?: string | string[] | undefined;
1212
+ project?: string | string[] | undefined;
1213
+ } | undefined;
1194
1214
  'semantic-release'?: string | boolean | string[] | {
1195
1215
  config?: string | string[] | undefined;
1196
1216
  entry?: string | string[] | undefined;
@@ -1,4 +1,5 @@
1
1
  import { toAlias, toDependency, toEntry, toIgnore, toProductionEntry } from "../../util/input.js";
2
+ import { join } from "../../util/path.js";
2
3
  import { hasDependency } from "../../util/plugin.js";
3
4
  import { CORE_CLIENT_API, resolveConfigItems } from "./helpers.js";
4
5
  const title = 'Docusaurus';
@@ -7,22 +8,36 @@ const isEnabled = ({ dependencies }) => hasDependency(dependencies, enablers);
7
8
  const config = ['docusaurus.config.{js,mjs,ts}'];
8
9
  const production = ['src/pages/**/*.{js,ts,jsx,tsx}', '{blog,docs}/**/*.mdx', 'versioned_docs/**/*.{mdx,jsx,tsx}'];
9
10
  const entry = ['babel.config.{js,cjs,mjs,cts}'];
11
+ const resolveStaticAssets = (items, cwd) => {
12
+ const entries = [];
13
+ for (const item of items ?? []) {
14
+ const value = typeof item === 'string' ? item : (item.src ?? item.href);
15
+ if (typeof value === 'string' && !value.includes('://'))
16
+ entries.push(toProductionEntry(join(cwd, 'static', value)));
17
+ }
18
+ return entries;
19
+ };
10
20
  const resolveConfig = async (config, options) => {
11
21
  const themes = await resolveConfigItems(config.themes ?? [], 'theme', options);
12
22
  const plugins = await resolveConfigItems(config.plugins ?? [], 'plugin', options);
13
23
  const presets = await resolveConfigItems(config.presets ?? [], 'preset', options);
14
24
  const hasClassicTheme = options.manifest.dependencies?.['@docusaurus/theme-classic'] ||
15
25
  options.manifest.dependencies?.['@docusaurus/preset-classic'];
26
+ const scripts = resolveStaticAssets(config.scripts ?? [], options.cwd);
27
+ const stylesheets = resolveStaticAssets(config.stylesheets ?? [], options.cwd);
16
28
  return [
17
29
  toAlias('@site/*', './*'),
18
30
  toDependency('@docusaurus/module-type-aliases', { optional: true }),
19
31
  ...(hasClassicTheme ? [toIgnore('(@theme|@theme-init|@theme-original)/*', 'dependencies')] : []),
20
32
  toIgnore(`@docusaurus/(${CORE_CLIENT_API.join('|')})`, 'dependencies'),
33
+ ...(config.future?.experimental_faster ? [toDependency('@docusaurus/faster')] : []),
21
34
  ...production.map(id => toProductionEntry(id)),
22
35
  ...entry.map(id => toEntry(id)),
23
36
  ...themes,
24
37
  ...plugins,
25
38
  ...presets,
39
+ ...scripts,
40
+ ...stylesheets,
26
41
  ];
27
42
  };
28
43
  const plugin = {
@@ -30,11 +30,27 @@ type PluginConfig = string | [string, PluginOptions] | false | null | {
30
30
  type PresetConfig = string | [string, PresetOptions] | false | null;
31
31
  type Config = PresetConfig | PluginConfig;
32
32
  export type ConfigItem = Config | (() => Config);
33
+ type ScriptTag = {
34
+ src: string;
35
+ [key: string]: unknown;
36
+ };
37
+ type StylesheetLink = {
38
+ href: string;
39
+ [key: string]: unknown;
40
+ };
33
41
  export type DocusaurusConfig = {
34
42
  title: string;
35
43
  url: string;
36
44
  themes?: PluginConfig[];
37
45
  plugins?: PluginConfig[];
38
46
  presets: PresetConfig[];
47
+ scripts?: (string | ScriptTag)[];
48
+ stylesheets?: (string | StylesheetLink)[];
49
+ future?: {
50
+ experimental_faster?: boolean | {
51
+ [key: string]: unknown;
52
+ };
53
+ [key: string]: unknown;
54
+ };
39
55
  };
40
56
  export {};
@@ -90,6 +90,7 @@ export declare const Plugins: {
90
90
  prettier: import("../types/config.ts").Plugin;
91
91
  prisma: import("../types/config.ts").Plugin;
92
92
  qwik: import("../types/config.ts").Plugin;
93
+ raycast: import("../types/config.ts").Plugin;
93
94
  'react-cosmos': import("../types/config.ts").Plugin;
94
95
  'react-native': import("../types/config.ts").Plugin;
95
96
  'react-router': import("../types/config.ts").Plugin;
@@ -102,6 +103,7 @@ export declare const Plugins: {
102
103
  rslib: import("../types/config.ts").Plugin;
103
104
  rspack: import("../types/config.ts").Plugin;
104
105
  rstest: import("../types/config.ts").Plugin;
106
+ sanity: import("../types/config.ts").Plugin;
105
107
  'semantic-release': import("../types/config.ts").Plugin;
106
108
  sentry: import("../types/config.ts").Plugin;
107
109
  'simple-git-hooks': import("../types/config.ts").Plugin;
@@ -84,6 +84,7 @@ import { default as preconstruct } from "./preconstruct/index.js";
84
84
  import { default as prettier } from "./prettier/index.js";
85
85
  import { default as prisma } from "./prisma/index.js";
86
86
  import { default as qwik } from "./qwik/index.js";
87
+ import { default as raycast } from "./raycast/index.js";
87
88
  import { default as reactCosmos } from "./react-cosmos/index.js";
88
89
  import { default as reactNative } from "./react-native/index.js";
89
90
  import { default as reactRouter } from "./react-router/index.js";
@@ -96,6 +97,7 @@ import { default as rsbuild } from "./rsbuild/index.js";
96
97
  import { default as rslib } from "./rslib/index.js";
97
98
  import { default as rspack } from "./rspack/index.js";
98
99
  import { default as rstest } from "./rstest/index.js";
100
+ import { default as sanity } from "./sanity/index.js";
99
101
  import { default as semanticRelease } from "./semantic-release/index.js";
100
102
  import { default as sentry } from "./sentry/index.js";
101
103
  import { default as simpleGitHooks } from "./simple-git-hooks/index.js";
@@ -224,6 +226,7 @@ export const Plugins = {
224
226
  prettier,
225
227
  prisma,
226
228
  qwik,
229
+ raycast,
227
230
  'react-cosmos': reactCosmos,
228
231
  'react-native': reactNative,
229
232
  'react-router': reactRouter,
@@ -236,6 +239,7 @@ export const Plugins = {
236
239
  rslib,
237
240
  rspack,
238
241
  rstest,
242
+ sanity,
239
243
  'semantic-release': semanticRelease,
240
244
  sentry,
241
245
  'simple-git-hooks': simpleGitHooks,
@@ -162,9 +162,12 @@ const resolveConfig = async (localConfig, options) => {
162
162
  }
163
163
  for (const ext of localConfig.extends ?? []) {
164
164
  const resolved = resolveAlias(ext, srcDir, cwd);
165
- for (const cfg of _syncGlob({ cwd: resolved, patterns: config })) {
166
- inputs.push(toConfig('nuxt', join(resolved, cfg)));
167
- }
165
+ const configs = _syncGlob({ cwd: resolved, patterns: config });
166
+ if (configs.length > 0)
167
+ for (const cfg of configs)
168
+ inputs.push(toConfig('nuxt', join(resolved, cfg)));
169
+ else
170
+ inputs.push(toDependency(ext));
168
171
  }
169
172
  for (const layerConfig of findLayerConfigs(cwd)) {
170
173
  inputs.push(toConfig('nuxt', layerConfig));
@@ -2,7 +2,7 @@ import { hasDependency } from "../../util/plugin.js";
2
2
  const title = 'Oxfmt';
3
3
  const enablers = ['oxfmt'];
4
4
  const isEnabled = ({ dependencies }) => hasDependency(dependencies, enablers);
5
- const config = ['.oxfmtrc.json', '.oxfmtrc.jsonc'];
5
+ const config = ['.oxfmtrc.json', '.oxfmtrc.jsonc', 'oxfmt.config.ts'];
6
6
  const args = {
7
7
  config: true,
8
8
  };
@@ -0,0 +1,3 @@
1
+ import type { Plugin } from '../../types/config.ts';
2
+ declare const plugin: Plugin;
3
+ export default plugin;
@@ -0,0 +1,25 @@
1
+ import { compact } from "../../util/array.js";
2
+ import { toProductionEntry } from "../../util/input.js";
3
+ import { hasDependency } from "../../util/plugin.js";
4
+ const title = 'Raycast';
5
+ const enablers = ['@raycast/api'];
6
+ const isEnabled = ({ dependencies }) => hasDependency(dependencies, enablers);
7
+ const config = ['package.json'];
8
+ const packageJsonPath = (manifest) => manifest;
9
+ const mapEntries = (items, directory) => {
10
+ const names = compact((items ?? []).map(item => (typeof item.name === 'string' ? item.name : undefined)));
11
+ return names.map(name => toProductionEntry(`${directory}${name}.{js,jsx,ts,tsx}`));
12
+ };
13
+ const resolveConfig = async (manifest) => [
14
+ ...mapEntries(manifest.commands, 'src/'),
15
+ ...mapEntries(manifest.tools, 'src/tools/'),
16
+ ];
17
+ const plugin = {
18
+ title,
19
+ enablers,
20
+ isEnabled,
21
+ config,
22
+ packageJsonPath,
23
+ resolveConfig,
24
+ };
25
+ export default plugin;
@@ -0,0 +1,10 @@
1
+ export type RaycastManifestCommand = {
2
+ name?: unknown;
3
+ };
4
+ export type RaycastManifestTool = {
5
+ name?: unknown;
6
+ };
7
+ export type RaycastManifest = {
8
+ commands?: RaycastManifestCommand[];
9
+ tools?: RaycastManifestTool[];
10
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,3 @@
1
+ import type { Plugin } from '../../types/config.ts';
2
+ declare const plugin: Plugin;
3
+ export default plugin;
@@ -0,0 +1,12 @@
1
+ import { hasDependency } from "../../util/plugin.js";
2
+ const title = 'Sanity';
3
+ const enablers = ['sanity'];
4
+ const isEnabled = ({ dependencies }) => hasDependency(dependencies, enablers);
5
+ const entry = ['sanity.config.{js,jsx,ts,tsx}', 'sanity.cli.{ts,js}', 'sanity.blueprint.{ts,js,json}'];
6
+ const plugin = {
7
+ title,
8
+ enablers,
9
+ isEnabled,
10
+ entry,
11
+ };
12
+ export default plugin;
@@ -432,6 +432,11 @@ export declare const workspaceConfigurationSchema: z.ZodMiniObject<{
432
432
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
433
433
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
434
434
  }, z.core.$strip>]>>;
435
+ raycast: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
436
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
437
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
438
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
439
+ }, z.core.$strip>]>>;
435
440
  'react-cosmos': z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
436
441
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
437
442
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -492,6 +497,11 @@ export declare const workspaceConfigurationSchema: z.ZodMiniObject<{
492
497
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
493
498
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
494
499
  }, z.core.$strip>]>>;
500
+ sanity: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
501
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
502
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
503
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
504
+ }, z.core.$strip>]>>;
495
505
  'semantic-release': z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
496
506
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
497
507
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -1139,6 +1149,11 @@ export declare const knipConfigurationSchema: z.ZodMiniObject<{
1139
1149
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1140
1150
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1141
1151
  }, z.core.$strip>]>>;
1152
+ raycast: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1153
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1154
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1155
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1156
+ }, z.core.$strip>]>>;
1142
1157
  'react-cosmos': z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1143
1158
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1144
1159
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -1199,6 +1214,11 @@ export declare const knipConfigurationSchema: z.ZodMiniObject<{
1199
1214
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1200
1215
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1201
1216
  }, z.core.$strip>]>>;
1217
+ sanity: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1218
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1219
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1220
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1221
+ }, z.core.$strip>]>>;
1202
1222
  'semantic-release': z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1203
1223
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1204
1224
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -1835,6 +1855,11 @@ export declare const knipConfigurationSchema: z.ZodMiniObject<{
1835
1855
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1836
1856
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1837
1857
  }, z.core.$strip>]>>;
1858
+ raycast: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1859
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1860
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1861
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1862
+ }, z.core.$strip>]>>;
1838
1863
  'react-cosmos': z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1839
1864
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1840
1865
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -1895,6 +1920,11 @@ export declare const knipConfigurationSchema: z.ZodMiniObject<{
1895
1920
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1896
1921
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1897
1922
  }, z.core.$strip>]>>;
1923
+ sanity: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1924
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1925
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1926
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1927
+ }, z.core.$strip>]>>;
1898
1928
  'semantic-release': z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
1899
1929
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
1900
1930
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -436,6 +436,11 @@ export declare const pluginsSchema: z.ZodMiniObject<{
436
436
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
437
437
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
438
438
  }, z.core.$strip>]>;
439
+ raycast: z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
440
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
441
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
442
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
443
+ }, z.core.$strip>]>;
439
444
  'react-cosmos': z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
440
445
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
441
446
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -496,6 +501,11 @@ export declare const pluginsSchema: z.ZodMiniObject<{
496
501
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
497
502
  project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
498
503
  }, z.core.$strip>]>;
504
+ sanity: z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
505
+ config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
506
+ entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
507
+ project: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
508
+ }, z.core.$strip>]>;
499
509
  'semantic-release': z.ZodMiniUnion<readonly [z.ZodMiniBoolean<boolean>, z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>, z.ZodMiniObject<{
500
510
  config: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
501
511
  entry: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniString<string>, z.ZodMiniArray<z.ZodMiniString<string>>]>>;
@@ -96,6 +96,7 @@ export const pluginsSchema = z.object({
96
96
  prettier: pluginSchema,
97
97
  prisma: pluginSchema,
98
98
  qwik: pluginSchema,
99
+ raycast: pluginSchema,
99
100
  'react-cosmos': pluginSchema,
100
101
  'react-native': pluginSchema,
101
102
  'react-router': pluginSchema,
@@ -108,6 +109,7 @@ export const pluginsSchema = z.object({
108
109
  rslib: pluginSchema,
109
110
  rspack: pluginSchema,
110
111
  rstest: pluginSchema,
112
+ sanity: pluginSchema,
111
113
  'semantic-release': pluginSchema,
112
114
  sentry: pluginSchema,
113
115
  'simple-git-hooks': pluginSchema,
@@ -1,2 +1,2 @@
1
- export type PluginName = 'angular' | 'astro' | 'astro-db' | 'astro-og-canvas' | 'ava' | 'babel' | 'biome' | 'bumpp' | 'bun' | 'c8' | 'capacitor' | 'changelogen' | 'changelogithub' | 'changesets' | 'commitizen' | 'commitlint' | 'convex' | 'create-typescript-app' | 'cspell' | 'cucumber' | 'cypress' | 'danger' | 'dependency-cruiser' | 'docusaurus' | 'dotenv' | 'drizzle' | 'eleventy' | 'eslint' | 'execa' | 'expo' | 'expressive-code' | 'gatsby' | 'github-action' | 'github-actions' | 'glob' | 'graphql-codegen' | 'hardhat' | 'husky' | 'i18next-parser' | 'jest' | 'karma' | 'knex' | 'ladle' | 'lefthook' | 'lint-staged' | 'linthtml' | 'lockfile-lint' | 'lost-pixel' | 'markdownlint' | 'mdx' | 'mdxlint' | 'metro' | 'mocha' | 'moonrepo' | 'msw' | 'nano-staged' | 'nest' | 'netlify' | 'next' | 'next-intl' | 'next-mdx' | 'nitro' | 'node' | 'node-modules-inspector' | 'nodemon' | 'npm-package-json-lint' | 'nuxt' | 'nx' | 'nyc' | 'oclif' | 'openapi-ts' | 'oxfmt' | 'oxlint' | 'parcel' | 'payload' | 'playwright' | 'playwright-ct' | 'playwright-test' | 'plop' | 'pm2' | 'pnpm' | 'postcss' | 'preconstruct' | 'prettier' | 'prisma' | 'qwik' | 'react-cosmos' | 'react-native' | 'react-router' | 'relay' | 'release-it' | 'remark' | 'remix' | 'rollup' | 'rsbuild' | 'rslib' | 'rspack' | 'rstest' | 'semantic-release' | 'sentry' | 'simple-git-hooks' | 'size-limit' | 'sst' | 'starlight' | 'storybook' | 'stryker' | 'stylelint' | 'svelte' | 'sveltekit' | 'svgo' | 'svgr' | 'swc' | 'syncpack' | 'tailwind' | 'tanstack-router' | 'taskfile' | 'travis' | 'ts-node' | 'tsdown' | 'tsup' | 'tsx' | 'typedoc' | 'typescript' | 'unbuild' | 'unocss' | 'vercel-og' | 'vike' | 'vite' | 'vitepress' | 'vitest' | 'vue' | 'webdriver-io' | 'webpack' | 'wireit' | 'wrangler' | 'xo' | 'yarn' | 'yorkie' | 'zx';
2
- export declare const pluginNames: readonly ["angular", "astro", "astro-db", "astro-og-canvas", "ava", "babel", "biome", "bumpp", "bun", "c8", "capacitor", "changelogen", "changelogithub", "changesets", "commitizen", "commitlint", "convex", "create-typescript-app", "cspell", "cucumber", "cypress", "danger", "dependency-cruiser", "docusaurus", "dotenv", "drizzle", "eleventy", "eslint", "execa", "expo", "expressive-code", "gatsby", "github-action", "github-actions", "glob", "graphql-codegen", "hardhat", "husky", "i18next-parser", "jest", "karma", "knex", "ladle", "lefthook", "lint-staged", "linthtml", "lockfile-lint", "lost-pixel", "markdownlint", "mdx", "mdxlint", "metro", "mocha", "moonrepo", "msw", "nano-staged", "nest", "netlify", "next", "next-intl", "next-mdx", "nitro", "node", "node-modules-inspector", "nodemon", "npm-package-json-lint", "nuxt", "nx", "nyc", "oclif", "openapi-ts", "oxfmt", "oxlint", "parcel", "payload", "playwright", "playwright-ct", "playwright-test", "plop", "pm2", "pnpm", "postcss", "preconstruct", "prettier", "prisma", "qwik", "react-cosmos", "react-native", "react-router", "relay", "release-it", "remark", "remix", "rollup", "rsbuild", "rslib", "rspack", "rstest", "semantic-release", "sentry", "simple-git-hooks", "size-limit", "sst", "starlight", "storybook", "stryker", "stylelint", "svelte", "sveltekit", "svgo", "svgr", "swc", "syncpack", "tailwind", "tanstack-router", "taskfile", "travis", "ts-node", "tsdown", "tsup", "tsx", "typedoc", "typescript", "unbuild", "unocss", "vercel-og", "vike", "vite", "vitepress", "vitest", "vue", "webdriver-io", "webpack", "wireit", "wrangler", "xo", "yarn", "yorkie", "zx"];
1
+ export type PluginName = 'angular' | 'astro' | 'astro-db' | 'astro-og-canvas' | 'ava' | 'babel' | 'biome' | 'bumpp' | 'bun' | 'c8' | 'capacitor' | 'changelogen' | 'changelogithub' | 'changesets' | 'commitizen' | 'commitlint' | 'convex' | 'create-typescript-app' | 'cspell' | 'cucumber' | 'cypress' | 'danger' | 'dependency-cruiser' | 'docusaurus' | 'dotenv' | 'drizzle' | 'eleventy' | 'eslint' | 'execa' | 'expo' | 'expressive-code' | 'gatsby' | 'github-action' | 'github-actions' | 'glob' | 'graphql-codegen' | 'hardhat' | 'husky' | 'i18next-parser' | 'jest' | 'karma' | 'knex' | 'ladle' | 'lefthook' | 'lint-staged' | 'linthtml' | 'lockfile-lint' | 'lost-pixel' | 'markdownlint' | 'mdx' | 'mdxlint' | 'metro' | 'mocha' | 'moonrepo' | 'msw' | 'nano-staged' | 'nest' | 'netlify' | 'next' | 'next-intl' | 'next-mdx' | 'nitro' | 'node' | 'node-modules-inspector' | 'nodemon' | 'npm-package-json-lint' | 'nuxt' | 'nx' | 'nyc' | 'oclif' | 'openapi-ts' | 'oxfmt' | 'oxlint' | 'parcel' | 'payload' | 'playwright' | 'playwright-ct' | 'playwright-test' | 'plop' | 'pm2' | 'pnpm' | 'postcss' | 'preconstruct' | 'prettier' | 'prisma' | 'qwik' | 'raycast' | 'react-cosmos' | 'react-native' | 'react-router' | 'relay' | 'release-it' | 'remark' | 'remix' | 'rollup' | 'rsbuild' | 'rslib' | 'rspack' | 'rstest' | 'sanity' | 'semantic-release' | 'sentry' | 'simple-git-hooks' | 'size-limit' | 'sst' | 'starlight' | 'storybook' | 'stryker' | 'stylelint' | 'svelte' | 'sveltekit' | 'svgo' | 'svgr' | 'swc' | 'syncpack' | 'tailwind' | 'tanstack-router' | 'taskfile' | 'travis' | 'ts-node' | 'tsdown' | 'tsup' | 'tsx' | 'typedoc' | 'typescript' | 'unbuild' | 'unocss' | 'vercel-og' | 'vike' | 'vite' | 'vitepress' | 'vitest' | 'vue' | 'webdriver-io' | 'webpack' | 'wireit' | 'wrangler' | 'xo' | 'yarn' | 'yorkie' | 'zx';
2
+ export declare const pluginNames: readonly ["angular", "astro", "astro-db", "astro-og-canvas", "ava", "babel", "biome", "bumpp", "bun", "c8", "capacitor", "changelogen", "changelogithub", "changesets", "commitizen", "commitlint", "convex", "create-typescript-app", "cspell", "cucumber", "cypress", "danger", "dependency-cruiser", "docusaurus", "dotenv", "drizzle", "eleventy", "eslint", "execa", "expo", "expressive-code", "gatsby", "github-action", "github-actions", "glob", "graphql-codegen", "hardhat", "husky", "i18next-parser", "jest", "karma", "knex", "ladle", "lefthook", "lint-staged", "linthtml", "lockfile-lint", "lost-pixel", "markdownlint", "mdx", "mdxlint", "metro", "mocha", "moonrepo", "msw", "nano-staged", "nest", "netlify", "next", "next-intl", "next-mdx", "nitro", "node", "node-modules-inspector", "nodemon", "npm-package-json-lint", "nuxt", "nx", "nyc", "oclif", "openapi-ts", "oxfmt", "oxlint", "parcel", "payload", "playwright", "playwright-ct", "playwright-test", "plop", "pm2", "pnpm", "postcss", "preconstruct", "prettier", "prisma", "qwik", "raycast", "react-cosmos", "react-native", "react-router", "relay", "release-it", "remark", "remix", "rollup", "rsbuild", "rslib", "rspack", "rstest", "sanity", "semantic-release", "sentry", "simple-git-hooks", "size-limit", "sst", "starlight", "storybook", "stryker", "stylelint", "svelte", "sveltekit", "svgo", "svgr", "swc", "syncpack", "tailwind", "tanstack-router", "taskfile", "travis", "ts-node", "tsdown", "tsup", "tsx", "typedoc", "typescript", "unbuild", "unocss", "vercel-og", "vike", "vite", "vitepress", "vitest", "vue", "webdriver-io", "webpack", "wireit", "wrangler", "xo", "yarn", "yorkie", "zx"];
@@ -85,6 +85,7 @@ export const pluginNames = [
85
85
  'prettier',
86
86
  'prisma',
87
87
  'qwik',
88
+ 'raycast',
88
89
  'react-cosmos',
89
90
  'react-native',
90
91
  'react-router',
@@ -97,6 +98,7 @@ export const pluginNames = [
97
98
  'rslib',
98
99
  'rspack',
99
100
  'rstest',
101
+ 'sanity',
100
102
  'semantic-release',
101
103
  'sentry',
102
104
  'simple-git-hooks',
@@ -16,7 +16,7 @@ import getScriptVisitors from "./visitors/scripts/index.js";
16
16
  const isInTopLevelScope = (node, sourceFile) => {
17
17
  let current = node.parent;
18
18
  while (current && current !== sourceFile) {
19
- if (ts.isFunctionLike(current) || ts.isClassLike(current))
19
+ if (ts.isFunctionLike(current) || ts.isClassLike(current) || ts.isModuleDeclaration(current))
20
20
  return false;
21
21
  current = current.parent;
22
22
  }
@@ -475,6 +475,11 @@ export declare const createOptions: (options: CreateOptions) => Promise<{
475
475
  entry?: string | string[] | undefined;
476
476
  project?: string | string[] | undefined;
477
477
  } | undefined;
478
+ raycast?: string | boolean | string[] | {
479
+ config?: string | string[] | undefined;
480
+ entry?: string | string[] | undefined;
481
+ project?: string | string[] | undefined;
482
+ } | undefined;
478
483
  'react-cosmos'?: string | boolean | string[] | {
479
484
  config?: string | string[] | undefined;
480
485
  entry?: string | string[] | undefined;
@@ -535,6 +540,11 @@ export declare const createOptions: (options: CreateOptions) => Promise<{
535
540
  entry?: string | string[] | undefined;
536
541
  project?: string | string[] | undefined;
537
542
  } | undefined;
543
+ sanity?: string | boolean | string[] | {
544
+ config?: string | string[] | undefined;
545
+ entry?: string | string[] | undefined;
546
+ project?: string | string[] | undefined;
547
+ } | undefined;
538
548
  'semantic-release'?: string | boolean | string[] | {
539
549
  config?: string | string[] | undefined;
540
550
  entry?: string | string[] | undefined;
@@ -1171,6 +1181,11 @@ export declare const createOptions: (options: CreateOptions) => Promise<{
1171
1181
  entry?: string | string[] | undefined;
1172
1182
  project?: string | string[] | undefined;
1173
1183
  } | undefined;
1184
+ raycast?: string | boolean | string[] | {
1185
+ config?: string | string[] | undefined;
1186
+ entry?: string | string[] | undefined;
1187
+ project?: string | string[] | undefined;
1188
+ } | undefined;
1174
1189
  'react-cosmos'?: string | boolean | string[] | {
1175
1190
  config?: string | string[] | undefined;
1176
1191
  entry?: string | string[] | undefined;
@@ -1231,6 +1246,11 @@ export declare const createOptions: (options: CreateOptions) => Promise<{
1231
1246
  entry?: string | string[] | undefined;
1232
1247
  project?: string | string[] | undefined;
1233
1248
  } | undefined;
1249
+ sanity?: string | boolean | string[] | {
1250
+ config?: string | string[] | undefined;
1251
+ entry?: string | string[] | undefined;
1252
+ project?: string | string[] | undefined;
1253
+ } | undefined;
1234
1254
  'semantic-release'?: string | boolean | string[] | {
1235
1255
  config?: string | string[] | undefined;
1236
1256
  entry?: string | string[] | undefined;
@@ -1,4 +1,4 @@
1
- export declare const getPackageNameFromModuleSpecifier: (moduleSpecifier: string) => string | undefined;
1
+ export declare const getPackageNameFromModuleSpecifier: (specifier: string) => string | undefined;
2
2
  export declare const getPackageNameFromFilePath: (value: string) => string;
3
3
  export declare const getPackageNameFromSpecifier: (specifier: string) => string | undefined;
4
4
  export declare const isStartsLikePackageName: (specifier: string) => boolean;
@@ -1,10 +1,21 @@
1
1
  import { DT_SCOPE, PROTOCOL_VIRTUAL } from "../constants.js";
2
2
  import { isAbsolute, isInNodeModules, toPosix } from "./path.js";
3
- export const getPackageNameFromModuleSpecifier = (moduleSpecifier) => {
4
- if (!isStartsLikePackageName(moduleSpecifier))
3
+ export const getPackageNameFromModuleSpecifier = (specifier) => {
4
+ if (!isStartsLikePackageName(specifier))
5
5
  return;
6
- const parts = moduleSpecifier.split('/').slice(0, 2);
7
- return moduleSpecifier.startsWith('@') ? parts.join('/') : parts[0];
6
+ let start = 0;
7
+ if (specifier.charCodeAt(0) === 64) {
8
+ const slash = specifier.indexOf('/', 1);
9
+ if (slash === -1)
10
+ return specifier;
11
+ start = slash + 1;
12
+ }
13
+ for (let i = start; i < specifier.length; i++) {
14
+ const ch = specifier.charCodeAt(i);
15
+ if (ch === 47 || ch === 64)
16
+ return specifier.slice(0, i);
17
+ }
18
+ return specifier;
8
19
  };
9
20
  const lastPackageNameMatch = /(?<=node_modules\/)(@[^/]+\/[^/]+|[^/]+)/g;
10
21
  export const getPackageNameFromFilePath = (value) => {
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const version = "5.87.0";
1
+ export declare const version = "5.88.1";
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const version = '5.87.0';
1
+ export const version = '5.88.1';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "knip",
3
- "version": "5.87.0",
3
+ "version": "5.88.1",
4
4
  "description": "Find and fix unused dependencies, exports and files in your TypeScript and JavaScript projects",
5
5
  "keywords": [
6
6
  "analysis",
package/schema.json CHANGED
@@ -724,6 +724,10 @@
724
724
  "title": "rstest plugin configuration (https://knip.dev/reference/plugins/rstest)",
725
725
  "$ref": "#/definitions/plugin"
726
726
  },
727
+ "sanity": {
728
+ "title": "sanity plugin configuration (https://knip.dev/reference/plugins/sanity)",
729
+ "$ref": "#/definitions/plugin"
730
+ },
727
731
  "semantic-release": {
728
732
  "title": "semantic-release plugin configuration (https://knip.dev/reference/plugins/semantic-release)",
729
733
  "$ref": "#/definitions/plugin"