Open up a Terminal window. (If you have never seen Terminal before, go to Spotlight Search and type "Terminal.")
In the Terminal box, try this:
defaults read com.google.Chrome AppleLanguages
If you see this:
| // The code is based on https://gist.github.com/kottenator/9d936eb3e4e3c3e02598#gistcomment-3238804 | |
| type PageItem = number | "..."; | |
| export const getRange = (start: number, end: number): PageItem[] => { | |
| if (end < start) throw Error(`End number must be higher then start number: start ${start}, end ${start}`); | |
| const rangeLength = end - start + 1; | |
| return Array(rangeLength) | |
| .fill(0) |
| export function convertBytes(bytes: number, options: { useBinaryUnits?: boolean; decimals?: number } = {}): string { | |
| const { useBinaryUnits = false, decimals = 2 } = options; | |
| if (decimals < 0) { | |
| throw new Error(`Invalid decimals ${decimals}`); | |
| } | |
| const base = useBinaryUnits ? 1024 : 1000; | |
| const units = useBinaryUnits | |
| ? ["Bytes", "KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB"] |
| import type { API, FileInfo } from "jscodeshift"; | |
| // @graphql-codegen/typescript-react-apollo package generates SuspenseQuery functions that are not supported in used apollo versions. | |
| // The codegen package does not provide an option to disable this feature, so we need to remove the generated SuspenseQuery functions manually. | |
| export default function transform(file: FileInfo, api: API): string | undefined { | |
| const j = api.jscodeshift.withParser("ts"); | |
| const root = j(file.source); | |
| // Find and comment out all function declarations that end with "SuspenseQuery" | |
| root |
| type Plurals = Record<Intl.LDMLPluralRule, string>; | |
| const DEFAULT_PLURALS: Plurals = { | |
| zero: "Bytes", | |
| one: "Byte", | |
| two: "Bytes", | |
| few: "Bytes", | |
| many: "Bytes", | |
| other: "Bytes", | |
| }; |