Skip to content
Snippets Groups Projects
Unverified Commit c3e73b46 authored by zero's avatar zero Committed by GitHub
Browse files

fix: add getInitData api (#6707)

parent a7a45731
Branches
Tags
No related merge requests found
---
'@modern-js/runtime': patch
---
fix: add missing getInitData api
fix: 添加缺失的 getInitData 接口
......@@ -234,6 +234,9 @@ export const useRuntimeContext = () => {
request: baseSSRContext.request || ({} as TSSRContext['request']),
response: baseSSRContext.response || ({} as TSSRContext['response']),
logger: baseSSRContext.logger || ({} as TSSRContext['logger']),
getInitData: () => {
return Object.freeze(context.initialData);
},
}
: ({} as TSSRContext);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment