( store: Record<string, V | undefined> )
| 91 | } |
| 92 | |
| 93 | function createFastMemoizeCache<V>( |
| 94 | store: Record<string, V | undefined> |
| 95 | ): Cache<string, V> { |
| 96 | return { |
| 97 | create() { |
| 98 | return { |
| 99 | get(key) { |
| 100 | return store[key] |
| 101 | }, |
| 102 | set(key, value) { |
| 103 | store[key] = value |
| 104 | }, |
| 105 | } |
| 106 | }, |
| 107 | } |
| 108 | } |
| 109 | |
| 110 | /** |
| 111 | * Create intl formatters and populate cache |