A lightweight TypeScript-based transpiler that converts a JavaScript-like syntax (JSCSS) into standard CSS, enabling developers to define styles inline using JSON-style objects. Version 1.0.0 is the initial release. The tool features class scoping, variable interpolation, and advanced selectors like getbyid. It enforces ultra-strict TypeScript compilation with runtime guards against undefined index accesses. Differentiators include type safety, no external CSS files, and inline style definition using JSON.
npm install csiynjNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Demonstrates converting a simple JSCSS string with a class and variable interpolation into CSS output.
Add 'strict', 'noUncheckedIndexedAccess', and 'verbatimModuleSyntax' to tsconfig.json.
Use ES module imports or set 'type': 'module' in package.json.
Ensure no trailing comma in bracket syntax; e.g., getbyid['main-title'] not getbyid['main-title',].
Validate JSCSS syntax: ensure all keys and strings are properly quoted and closed.
Use import syntax or set 'type': 'module' in your package.json.
Set 'strict': true or 'noUncheckedIndexedAccess': true in tsconfig.json.