WorkletSharedStorage: context property

Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.

Non-standard: This feature is non-standard and is not on a standards track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future.

The context read-only property of the WorkletSharedStorage interface contains contextual data passed into the shared storage worklet from the associated browsing context via the FencedFrameConfig.setSharedStorageContext() method.


A string representing the data. The value will match the latest value that was passed into the FencedFrameConfig.setSharedStorageContext() method prior to navigation to the FencedFrameConfig. If no value was set by setSharedStorageContext() prior to navigation, then context will return undefined.


See the main WorkletSharedStorage page for an example.


The context property is not currently defined in a specification.

Browser compatibility

BCD tables only load in the browser

See also