mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
* feat: Add `prefixfree` * chore(prefixfree): Require TypeScript 2.8 * fix(prefixfree): Enable `strictNullChecks` Co-Authored-By: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com>
28 lines
537 B
TypeScript
28 lines
537 B
TypeScript
window.StyleFix === StyleFix;
|
|
window.PrefixFree === PrefixFree;
|
|
|
|
StyleFix.register((css, raw, element) => {
|
|
return css + "\n/* Custom end comment */\n";
|
|
});
|
|
StyleFix.process();
|
|
|
|
const browser = (() => {
|
|
switch (PrefixFree.prefix) {
|
|
case "-moz-":
|
|
return "firefox";
|
|
case "-ms-":
|
|
return "ie";
|
|
case "-o-":
|
|
return "opera";
|
|
case "-webkit-":
|
|
return "chrome";
|
|
default:
|
|
return "unknown";
|
|
}
|
|
})();
|
|
|
|
// $ExpectError
|
|
if (browser === "safari") {
|
|
// There's no way to differentiate Safari from Chrome using just prefixes
|
|
}
|