fast-xml-parser 5.2.4 → 5.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/fxp.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- type X2jOptions = {
1
+ export type X2jOptions = {
2
2
  /**
3
3
  * Preserve the order of tags in resulting JS object
4
4
  *
@@ -64,7 +64,7 @@ type X2jOptions = {
64
64
  parseTagValue?: boolean;
65
65
 
66
66
  /**
67
- * Whether to parse tag value with `strnum` package
67
+ * Whether to parse attribute value with `strnum` package
68
68
  *
69
69
  * Defaults to `false`
70
70
  */
@@ -218,14 +218,14 @@ type X2jOptions = {
218
218
  captureMetaData?: boolean;
219
219
  };
220
220
 
221
- type strnumOptions = {
221
+ export type strnumOptions = {
222
222
  hex: boolean;
223
223
  leadingZeros: boolean,
224
224
  skipLike?: RegExp,
225
225
  eNotation?: boolean
226
226
  }
227
227
 
228
- type validationOptions = {
228
+ export type validationOptions = {
229
229
  /**
230
230
  * Whether to allow attributes without value
231
231
  *
@@ -241,7 +241,7 @@ type validationOptions = {
241
241
  unpairedTags?: string[];
242
242
  };
243
243
 
244
- type XmlBuilderOptions = {
244
+ export type XmlBuilderOptions = {
245
245
  /**
246
246
  * Give a prefix to the attribute name in the resulting JS object
247
247
  *
@@ -395,7 +395,7 @@ type XmlBuilderOptions = {
395
395
 
396
396
  type ESchema = string | object | Array<string|object>;
397
397
 
398
- type ValidationError = {
398
+ export type ValidationError = {
399
399
  err: {
400
400
  code: string;
401
401
  msg: string,
@@ -406,7 +406,7 @@ type ValidationError = {
406
406
 
407
407
  export class XMLParser {
408
408
  constructor(options?: X2jOptions);
409
- parse(xmlData: string | Buffer ,validationOptions?: validationOptions | boolean): any;
409
+ parse(xmlData: string | Uint8Array, validationOptions?: validationOptions | boolean): any;
410
410
  /**
411
411
  * Add Entity which is not by default supported by this library
412
412
  * @param entityIdentifier {string} Eg: 'ent' for &ent;