Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(format/flutter): document className option for flutter/class.dart format #1418

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1007,6 +1007,7 @@ Creates a Dart implementation file of a class with values
| -------------------------- | ------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `options.showFileHeader` | `boolean` | Whether or not to include a comment that has the build date. Defaults to `true` |
| `options.outputReferences` | `boolean \| OutputReferencesFunction` | Whether or not to keep [references](/reference/hooks/formats#references-in-output-files) (a -> b -> c) in the output. Defaults to `false`. Also allows passing a function to conditionally output references on a per token basis. |
| `options.className` | `string` | The name of the generated Dart Class |

Example:

Expand Down
1 change: 1 addition & 0 deletions lib/common/formats.js
Original file line number Diff line number Diff line change
Expand Up @@ -1655,6 +1655,7 @@ declare const ${moduleName}: ${JSON.stringify(treeWalker(dictionary.tokens), nul
* @typedef {Object} flutterClassOpts
* @property {boolean} [flutterClassOpts.showFileHeader=true] - Whether or not to include a comment that has the build date
* @property {OutputReferences} [flutterClassOpts.outputReferences=false] - Whether or not to keep [references](/#/formats?id=references-in-output-files) (a -> b -> c) in the output.
* @property {String} [flutterClassOpts.className] - The name of the generated Dart Class
* @param {FormatArgs & { options?: flutterClassOpts }} options
* @example
* ```dart
Expand Down
Loading