Extensions: {
[extensionIdentifier: string]: string | {
[key: string]: string;
} | {
[keyA: string]: {
[keyB: string]: string;
};
};
}
Type declaration
[extensionIdentifier: string]: string | {
[key: string]: string;
} | {
[keyA: string]: {
[keyB: string]: string;
};
}
A mapping of extension identifiers to extension definitions. Extensions may be widely standardized or application-specific, and extension definitions must be either:
string
s,string
s, orstring
s.This limitation encourages safety and wider compatibility across implementations.
To encode an array, it is recommended that each value be assigned to a numeric key indicating the item's index (beginning at
0
). Numerically-indexed objects are often a more useful and resilient data-transfer format than simple arrays because they simplify difference-only transmission: only modified indexes need to be transferred, and shifts in item order must be explicit, simplifying merges of conflicting updates.For encoding of more complex data, consider using base64 and/or string-encoded JSON.