diff --git a/types/papaparse/index.d.ts b/types/papaparse/index.d.ts index 2bac4442033840..dfadbe987f5778 100644 --- a/types/papaparse/index.d.ts +++ b/types/papaparse/index.d.ts @@ -82,6 +82,12 @@ export function unparse(data: T[] | UnparseObject, config?: UnparseConfig) /** An array of characters that are not allowed as delimiters. `\r`, `\n`, `"`, `\ufeff` */ export const BAD_DELIMITERS: readonly string[]; +/** + * The unicode Byte Order Mark (\ufeff). + * @see https://en.wikipedia.org/wiki/Byte_order_mark + */ +export const BYTE_ORDER_MARK: "\ufeff"; + /** The true delimiter. Invisible. ASCII code 30. Should be doing the job we strangely rely upon commas and tabs for. */ export const RECORD_SEP: "\x1E"; diff --git a/types/papaparse/papaparse-tests.ts b/types/papaparse/papaparse-tests.ts index d7c0f4ea428451..f2d17e0918dcfe 100644 --- a/types/papaparse/papaparse-tests.ts +++ b/types/papaparse/papaparse-tests.ts @@ -313,6 +313,7 @@ Papa.unparse( Papa.RECORD_SEP; Papa.UNIT_SEP; Papa.BAD_DELIMITERS; +Papa.BYTE_ORDER_MARK; /** * Parser