Zum Inhalt springen
Kitbay

experience-lwc-typescript-migrate

Apache-2.0Aktualisiert am 6. Nov. 20261.156GitHub-SterneEnthält Skripte

A Salesforce skill for converting an existing JavaScript Lightning Web Component to TypeScript.

Was der Skill vermittelt

A Salesforce skill for converting an existing JavaScript Lightning Web Component to TypeScript. The agent reads the component, renames the file with git mv so history is kept, adds type annotations based on bundled pattern files, and writes a declaration file limited to the properties and methods marked @api. It then compiles with tsc and runs the tests, finishing with a checklist of the expected bundle shape. A bundled shell script finds other components that use the one being converted. It needs git, jq and the TypeScript compiler and is not meant for writing new components.

Funktionen

  • Rename LWC JavaScript files to TypeScript with git mv
  • Add type annotations to a component
  • Generate a .d.ts file for the @api surface
  • Find components that consume the converted one