Get the absolute path to the compiled analysis worker script
(dist/analysis-worker.js). Pass it as workerScriptPath to WorkerPool
or to ParallelExecutor.executeParallel.
Each worker started from the script:
reads workerId and tsConfigPath from workerData and loads the whole
project from that tsconfig into its own ts-morph Project, because rules
need cross-file context
creates its own PublicApi and posts { type: 'ready', workerId }; if
loading fails it posts { type: 'init-error', workerId, error } and exits
For a task the worker loads the analysis rules of the plugins in
pluginIds (architecture, solid, angular, analyzer, standalone
or the full package names; standalone has no analysis rules), keeps only
the rules in ruleIds when the list is not empty, and runs them on
filePath, which must belong to the loaded project. A rule that throws is
skipped. All results get the severity warning. A failed task returns no
results and sets error.
Get the absolute path to the compiled analysis worker script (
dist/analysis-worker.js). Pass it asworkerScriptPathtoWorkerPoolor toParallelExecutor.executeParallel.Each worker started from the script:
workerIdandtsConfigPathfromworkerDataand loads the whole project from that tsconfig into its own ts-morphProject, because rules need cross-file contextPublicApiand posts{ type: 'ready', workerId }; if loading fails it posts{ type: 'init-error', workerId, error }and exitsFor a task the worker loads the analysis rules of the plugins in
pluginIds(architecture,solid,angular,analyzer,standaloneor the full package names;standalonehas no analysis rules), keeps only the rules inruleIdswhen the list is not empty, and runs them onfilePath, which must belong to the loaded project. A rule that throws is skipped. All results get the severitywarning. A failed task returns no results and setserror.