Turn on all of Microsoft's recommend lint rules
Biggest changes forced by this: alt tags for all images, resulting in new strings added to messages.json, and a new i18n paramter/prop added in a plot of places. Another change of note is that there are two new tslint.json files under ts/test and ts/styleguide to relax our rules a bit there. This required a change to our package.json script, as manually specifying the config file there made it ignore our tslint.json files in subdirectories
This commit is contained in:
parent
23586be6b0
commit
2988da0981
49 changed files with 311 additions and 123 deletions
|
@ -14,5 +14,6 @@ export const arrayBufferToObjectURL = ({
|
|||
}
|
||||
|
||||
const blob = new Blob([data], { type });
|
||||
|
||||
return URL.createObjectURL(blob);
|
||||
};
|
||||
|
|
|
@ -29,6 +29,7 @@ export function replaceColons(str: string) {
|
|||
if (code) {
|
||||
return instance.data[code][0][0];
|
||||
}
|
||||
|
||||
return m;
|
||||
});
|
||||
}
|
||||
|
@ -51,6 +52,7 @@ function getCountOfAllMatches(str: string, regex: RegExp) {
|
|||
|
||||
function hasNormalCharacters(str: string) {
|
||||
const noEmoji = str.replace(instance.rx_unified, '').trim();
|
||||
|
||||
return noEmoji.length > 0;
|
||||
}
|
||||
|
||||
|
@ -96,6 +98,7 @@ export function getReplacementData(
|
|||
variation,
|
||||
};
|
||||
}
|
||||
|
||||
return {
|
||||
value: unified,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue