rulvar API reference / @rulvar/planner / lintScript
Function: lintScript()
ts
function lintScript(source): {
diagnostics: PlanDiagnostic[];
errors: PlanDiagnostic[];
workflow?: CompiledWorkflow;
};Defined in: packages/planner/src/plan.ts:69
Lints a script BODY with the workflows preset plus compileScript. The body is wrapped in an async function for parsing (top-level return/await are legal in the dialect); reported lines shift back so they index into the body source.
Parameters
| Parameter | Type |
|---|---|
source | string |
Returns
ts
{
diagnostics: PlanDiagnostic[];
errors: PlanDiagnostic[];
workflow?: CompiledWorkflow;
}| Name | Type | Defined in |
|---|---|---|
diagnostics | PlanDiagnostic[] | packages/planner/src/plan.ts:70 |
errors | PlanDiagnostic[] | packages/planner/src/plan.ts:71 |
workflow? | CompiledWorkflow | packages/planner/src/plan.ts:72 |