You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ npx ts-node $PWD/index.ts
return new TSError(diagnosticText, diagnosticCodes);
^
TSError: ⨯ Unable to compile TypeScript:
index.ts:13:3 - error TS2322: Type 'true' is not assignable to type '(Directives & (boolean | null)) | undefined'.
13 directives: true,
Expected behaviour
Expect to be able to set the value to the value of true as documented here https://eemeli.org/yaml/#tostring-options
so that the addition is done at --- the top of the yaml file.
Versions (please complete the following information):
Environment: [e.g. Node.js 14.7.0 or Chrome 87.0]
yaml: 2.0.1
node: 14.18.2
ts-node: 10.0.0
The text was updated successfully, but these errors were encountered:
Thank you for reporting this! There was an internal document option used only by the composer with the same directives name. That's now been renamed as _directives so that the TS types don't conflict.
Describe the bug
To Reproduce
setup the project
Add the following code to
index.ts
:Run the script from terminal:
Expected behaviour
Expect to be able to set the value to the value of
true
as documented here https://eemeli.org/yaml/#tostring-optionsso that the addition is done at
---
the top of the yaml file.Versions (please complete the following information):
yaml
: 2.0.1node
: 14.18.2ts-node
: 10.0.0The text was updated successfully, but these errors were encountered: