Bun.stringWidth ambiguousIsNarrow option defaults to true (#9064)

* Bun.stringWidth ambiguousIsNarrow option defaults to true

* number was backwards too
This commit is contained in:
Meghan Denny
2024-02-23 20:27:10 -08:00
committed by GitHub
parent 72b700205a
commit 968065ca73
2 changed files with 4 additions and 4 deletions

View File

@@ -390,9 +390,9 @@ namespace Bun {
*/
countAnsiEscapeCodes?: boolean;
/**
* When it's ambiugous and `true`, count emoji as 2 characters wide. If `false`, emoji are counted as 1 character wide.
* When it's ambiugous and `true`, count emoji as 1 characters wide. If `false`, emoji are counted as 2 character wide.
*
* @default false
* @default true
*/
ambiguousIsNarrow?: boolean;
},

View File

@@ -87,9 +87,9 @@ declare module "bun" {
*/
countAnsiEscapeCodes?: boolean;
/**
* When it's ambiugous and `true`, count emoji as 2 characters wide. If `false`, emoji are counted as 1 character wide.
* When it's ambiugous and `true`, count emoji as 1 characters wide. If `false`, emoji are counted as 2 character wide.
*
* @default false
* @default true
*/
ambiguousIsNarrow?: boolean;
},