laplacenoma
Reactivity analyzer for signal-based library
Last updated a year ago by GitHub Actions .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install laplacenoma 
SYNC missed versions from official npm registry.

Laplacenoma

version downloads license

Laplacenoma is a reactivity analyzer built on top of the TypeScript language service, inspired by the reactivity visualization feature in vuejs/language-tools. Its goal is to provide framework-agnostic and configurable reactivity analysis.

Installation

pnpm i laplacenoma

Usage

import { createAnalyzer } from "laplacenoma";
import rulesVue from "laplacenoma/rules/vue";
import type ts from "typescript";

const analyzer = createAnalyzer({
  rules: rulesVue,
});

export function getReactivityAnalysis(
  ts: typeof import("typescript"),
  languageService: ts.LanguageService,
  fileName: string,
  position: number,
) {
  const program = languageService.getProgram()!;
  const sourceFile = program.getSourceFile(fileName)!;
  return analyzer.analyze(sourceFile, position, {
    typescript: ts,
    languageService,
  });
}

Current Tags

  • 0.0.3                                ...           latest (a year ago)

3 Versions

  • 0.0.3                                ...           a year ago
  • 0.0.2                                ...           a year ago
  • 0.0.1                                ...           a year ago
Maintainers (1)
Downloads
Total 9
Today 0
This Week 2
This Month 6
Last Day 0
Last Week 4
Last Month 0
Dependencies (0)
None
Dev Dependencies (8)
Dependents (1)

© 2010 - cnpmjs.org x YWFE | Home | YWFE