mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-16 11:42:04 +08:00
chore: update tslint rules (#7391)
This commit is contained in:
@ -83,6 +83,7 @@ function _generateAmpMap(): any {
|
||||
ampCodes.set(key, objCodes[key]);
|
||||
}
|
||||
}
|
||||
|
||||
return ampCodes;
|
||||
}
|
||||
|
||||
@ -101,6 +102,7 @@ function _HandleAmpEntities(found: string, decimalValue: string, hexValue: strin
|
||||
if (res) {
|
||||
return String.fromCharCode(res);
|
||||
}
|
||||
|
||||
// Invalid word; so we just return it
|
||||
return found;
|
||||
}
|
||||
@ -109,7 +111,7 @@ function _HandleAmpEntities(found: string, decimalValue: string, hexValue: strin
|
||||
}
|
||||
|
||||
return String.fromCharCode(parseInt(hexValue, 16));
|
||||
};
|
||||
}
|
||||
|
||||
export class XmlParser implements definition.XmlParser {
|
||||
//TODO: Add option to configure whether the parser should report ignorable whitespace, i.e. document formatting whitespace.
|
||||
@ -244,7 +246,7 @@ export class XmlParser implements definition.XmlParser {
|
||||
}
|
||||
|
||||
private _resolveNamespace(fullName: string): { prefix: string; namespace: string; name: string; } {
|
||||
const result: { prefix: string; namespace: string; name: string; } = { prefix: undefined, namespace: undefined, name: undefined }
|
||||
const result: { prefix: string; namespace: string; name: string; } = { prefix: undefined, namespace: undefined, name: undefined };
|
||||
result.prefix = "";
|
||||
if (fullName.indexOf(":") !== -1) {
|
||||
const split = fullName.split(":");
|
||||
@ -266,6 +268,7 @@ export class XmlParser implements definition.XmlParser {
|
||||
|
||||
if (result.prefix === key) {
|
||||
result.namespace = stackEntry[key];
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user