Feature: #98921 - Get multiple items by common key prefix from local storages
See forge#98921
Description
A new method
get
is added to the module
@typo3/
, affecting its
implementations
@typo3/
backend/ storage/ browser- session @typo3/
backend/ storage/ client
Impact
A developer is now able to obtain multiple items prefixed by a given key either
from
local
or
session
.
Example:
import Client from '@typo3/backend/storage/client';
Client.set('common-prefix-a', 'a');
Client.set('common-prefix-b', 'b');
Client.set('common-prefix-c', 'c');
const entries = Client.getByPrefix('common-prefix-');
// {'common-prefix-a': 'a', 'common-prefix-b': 'b', 'common-prefix-c': 'c'}
Copied!