connorjs / css-typed

TypeScript declaration generator for CSS files
https://npmjs.com/package/css-typed
MIT License
4 stars 1 forks source link

Customize output directory #4

Closed connorjs closed 3 months ago

connorjs commented 10 months ago

Overview

As a user, I want to choose where to css-typed generates the files, so that it can fit my repository’s directory structure/conventions.

Notes

connorjs commented 3 months ago

The plan is to release an --out-dir option (-o for short) that will change the root output directory. With the initial release, the directory structure will mirror the same file path (relative to cwd).

This means that it may include src in its structure. In the future, the tool could detect the root or take a root argument. Simply putting it under generated or artifacts/css-typed solves my primary .gitignore use case.

Using the option may require tweaking your tsconfig.json to properly find the generated files.