-
Notifications
You must be signed in to change notification settings - Fork 77
Open
Description
This issue would be just a chore. ✨
Thanks to #235, a nifty option named --allowArbitraryExtensions was added.
From my understanding, this option is thankfully available in the CLI as well as the configuration file.
Current Behavior
Unlike the availability, the option is currently documented in the section dedicated to configurations only available within the configuration file.
To confirm this, please refer L344 (… the following are options only available with the configuration file …) and around L355 below.
Lines 340 to 363 in e80c68e
| > Note: the configuration options are the same as the CLI options without the leading dashes (`--`). Only the full option name is supported (not aliases) in the configuration file. | |
| CLI options will take precedence over configuration file options. | |
| In addition to all CLI options, the following are options only available with the configuration file: | |
| ### `importer` | |
| - **Type**: `Importer | Importer[]` | |
| - **Default**: _none_ | |
| Define a [single custom SASS importer or an array of SASS importers](https://github.com/sass/sass/blob/f355f602fc15f55b0a0a795ebe6eb819963e08a5/js-api-doc/legacy/importer.d.ts#L51-L149). This should only be necessary if custom SASS importers are already being used in the build process. This is used internally to implement `aliases` and `aliasPrefixes`. | |
| Refer to [`lib/sass/importer.ts`](/blob/master/lib/sass/importer.ts) for more details and the `node-sass` and `sass` importer type definitions. | |
| ### `--allowArbitraryExtensions` | |
| - **Type**: `boolean` | |
| - **Default**: `false` | |
| - **Example**: `typed-scss-modules src --allowArbitraryExtensions` | |
| Output filenames that will be compatible with the "arbitrary file extensions" feature that was introduced in TypeScript 5.0. See [the docs](https://www.typescriptlang.org/tsconfig#allowArbitraryExtensions) for more info. | |
| In essence, the `*.scss.d.ts` extension now becomes `*.d.scss.ts` so that you can import SCSS modules in projects using ESM module resolution. |
Expected Behavior
It would be more understandable to relocate the documentation to a section a little preceding the current one. 👍
Metadata
Metadata
Assignees
Labels
No labels