Gets data from server-side code for use in client-side code.
A performance best practice is to get warmup data on the server for time-consuming operations, such as querying
collections or working with the results of network requests from external sites. You can write code that
sets the data from these operations as warmup data on the server. The client-side code can then get
that data without
performing the operations again.
Getting the warmupData
data retrieves data that was set on the server and makes the data accessible
from the client-side.
You can only get warmupData
in the client-side code.
null
if called while on the server.warmupData.set()
, it returns undefined
.Notes:
A name representing the data to return to the client-side. Until rendered, the data is undefined
.