Skip to content

Commit

Permalink
Merge pull request #1446 from bengie/usesDtcg-option-docs
Browse files Browse the repository at this point in the history
docs: add `usesDtcg` to createPropertyFormatter and formattedVariables
  • Loading branch information
jorenbroekema authored Feb 10, 2025
2 parents 2f3d629 + 844dea7 commit 85d12e0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/src/content/docs/reference/Utils/format-helpers.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ which uses: prefix, indentation, separator, suffix, and commentStyle.
| `options.format` | `string` | Available formats are: 'css', 'sass', 'less', and 'stylus'. If you want to customize the format and can't use one of those predefined formats, use the `formatting` option |
| `options.formatting` | `FormattingOptions` | Custom formatting properties that define parts of a declaration line in code. The configurable strings are: `prefix`, `indentation`, `separator`, `suffix`, `lineSeparator`, `fileHeaderTimestamp`, `header`, `footer`, `commentStyle` and `commentPosition`. Those are used to generate a line like this: `${indentation}${prefix}${token.name}${separator} ${prop.value}${suffix}`. The remaining formatting options are used for the fileHeader helper. |
| `options.themeable` | `boolean` | Whether tokens should default to being themeable. Defaults to false. |
| `options.usesDtcg` | `boolean` | Whether tokens use the DTCG standard. Defaults to `false` |

Example:

Expand Down Expand Up @@ -127,6 +128,7 @@ This is used to create lists of variables like Sass variables or CSS custom prop
| `options.outputReferences` | `boolean \| OutputReferencesFunction` | Whether or not to output references. You will want to pass this from the `options` object sent to the format function. Also allows passing a function to conditionally output references on a per token basis. |
| `options.formatting` | `Object` | Custom formatting properties that define parts of a comment in code. The configurable strings are: `prefix`, `lineSeparator`, `header`, and `footer`. |
| `options.themeable` | `boolean` | Whether tokens should default to being themeable. Defaults to `false`. |
| `options.usesDtcg` | `boolean` | Whether tokens use the DTCG standard. Defaults to `false` |

Example:

Expand Down

0 comments on commit 85d12e0

Please sign in to comment.