perf(nodejs): evaluate nodejs format string lazily (#2160)

* fix(nodejs): update format string

* test(nodejs): adjust tests to new format strings

* fix(nodejs): use once_cell's Lazy to implement hassleless lazy execution

* chore(nodejs): run rustfmt

Co-authored-by: Moritz Vetter <mv@3yourmind.com>
This commit is contained in:
Moritz Vetter
2021-01-20 19:03:48 +01:00
committed by GitHub
parent 8302a3ccb4
commit b5fd517972
3 changed files with 23 additions and 15 deletions
+1 -1
View File
@@ -1760,7 +1760,7 @@ The module will be shown if any of the following conditions are met:
| Option | Default | Description |
| ---------- | ---------------------------------- | -------------------------------------------------- |
| `format` | `"via [$symbol$version]($style) "` | The format for the module. |
| `format` | `"via [$symbol($version )]($style)"` | The format for the module. |
| `symbol` | `"⬢ "` | A format string representing the symbol of NodeJS. |
| `style` | `"bold green"` | The style for the module. |
| `disabled` | `false` | Disables the `nodejs` module. |