@alint-js/core 0.1.0 → 0.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.
- package/README.md +33 -0
- package/dist/agent.d.mts +1 -1
- package/dist/{define-CnBawoAI.d.mts → define-8BzWDcPs.d.mts} +1 -1
- package/dist/dsl.d.mts +3 -3
- package/dist/index.d.mts +59 -20
- package/dist/index.mjs +1720 -845
- package/dist/structured-output.d.mts +1 -1
- package/dist/{types-m5T_UL76.d.mts → types-DKylUrAn.d.mts} +17 -4
- package/package.json +2 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { b as RuleContext, z as ResolvedModel } from "./types-DKylUrAn.mjs";
|
|
2
2
|
import { GenericSchema, InferOutput } from "valibot";
|
|
3
3
|
import { JsonSchema } from "@valibot/to-json-schema";
|
|
4
4
|
import { Message } from "@xsai/shared-chat";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as ProcessorContext, h as SourceTarget, i as LanguageContext, l as ProcessorPostprocessContext, m as SourceRuntime, n as FileTarget, o as ProcessedSource, r as FunctionTarget, t as ClassTarget, u as SourceFile } from "./types-DSvXUVZ7.mjs";
|
|
1
|
+
import { c as ProcessorContext, h as SourceTarget, i as LanguageContext, l as ProcessorPostprocessContext, m as SourceRuntime, n as FileTarget, o as ProcessedSource, p as SourceRange, r as FunctionTarget, t as ClassTarget, u as SourceFile } from "./types-DSvXUVZ7.mjs";
|
|
2
2
|
import { GenericSchema, InferInput, InferOutput } from "valibot";
|
|
3
3
|
//#region src/config/types.d.ts
|
|
4
4
|
type ModelSize = 'large' | 'medium' | 'small';
|
|
@@ -169,11 +169,24 @@ interface ProcessorDefinition {
|
|
|
169
169
|
postprocess?: (diagnostics: DiagnosticDescriptor[], context: ProcessorPostprocessContext) => Awaitable<DiagnosticDescriptor[]>;
|
|
170
170
|
preprocess: (file: SourceFile, context: ProcessorContext) => Awaitable<ProcessedSource[]>;
|
|
171
171
|
}
|
|
172
|
+
interface ProjectFileEntry {
|
|
173
|
+
contentHash: string;
|
|
174
|
+
language: string;
|
|
175
|
+
path: string;
|
|
176
|
+
targetCount: number;
|
|
177
|
+
}
|
|
172
178
|
interface ProjectTarget {
|
|
173
|
-
files:
|
|
179
|
+
files: readonly ProjectFileEntry[];
|
|
174
180
|
kind: 'project';
|
|
175
181
|
root: string;
|
|
176
|
-
targets:
|
|
182
|
+
targets: readonly ProjectTargetEntry[];
|
|
183
|
+
}
|
|
184
|
+
interface ProjectTargetEntry {
|
|
185
|
+
filePath: string;
|
|
186
|
+
identity: string;
|
|
187
|
+
kind: string;
|
|
188
|
+
name?: string;
|
|
189
|
+
range?: SourceRange;
|
|
177
190
|
}
|
|
178
191
|
type RuleCacheConfig = boolean | {
|
|
179
192
|
level?: 'target';
|
|
@@ -249,4 +262,4 @@ interface RuleWithHandler {
|
|
|
249
262
|
}
|
|
250
263
|
type Target = DirectoryTarget | ProjectTarget | SourceTarget;
|
|
251
264
|
//#endregion
|
|
252
|
-
export {
|
|
265
|
+
export { RuleWithHandler as A, ResolvedProvider as B, RuleInferenceUsageRecord as C, RuleRegistry as D, RuleOptionsSchema as E, AgentTool as F, RunnerStatsConfig as G, ProviderDefinition as H, AgentUsage as I, SetupConfig as K, ModelRequirement as L, AgentAdapter as M, AgentRequest as N, RuleSeverity as O, AgentResult as P, ResolveModelOptions as R, RuleHandlers as S, RuleOptionsOutput as T, ProviderType as U, ModelSize as V, RunnerConfig as W, ProjectTargetEntry as _, AlintLinterOptions as a, RuleContext as b, DiagnosticLocation as c, IgnoreConfig as d, LanguageDefinition as f, ProjectTarget as g, ProjectFileEntry as h, AlintConfigItem as i, Target as j, RuleSpecializedHandlers as k, DirectoryTarget as l, ProcessorDefinition as m, AlintConfigExtends as n, Awaitable as o, PluginDefinition as p, SetupModelDefinition as q, AlintConfigInput as r, DiagnosticDescriptor as s, AlintConfig as t, EnabledRule as u, RuleCacheConfig as v, RuleOptionsInput as w, RuleDefinition as x, RuleConfigEntry as y, ResolvedModel as z };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alint-js/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.1",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
7
7
|
"types": "./dist/index.d.mts",
|
|
@@ -45,6 +45,7 @@
|
|
|
45
45
|
"sury": "^11.0.0-alpha.10"
|
|
46
46
|
},
|
|
47
47
|
"scripts": {
|
|
48
|
+
"bench": "vitest bench --config vitest.config.ts",
|
|
48
49
|
"build": "tsdown",
|
|
49
50
|
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
50
51
|
"test": "vitest run --config vitest.config.ts"
|