String 转 Module 转 String
来源:2-8 开发时的服务端渲染

翌子涵
2018-03-29
// 1. 读取到的内容是String const bundle = mfs.readFileSync(bundlePath, 'utf-8') // 2. 转模块 serverBundle = m.exports.default // 3. 再转字符串 const content = ReactDomServer.renderToString(serverBundle) renderToString 是此时会有Virtual-DOM Diff 吗?
写回答
1回答
-
Jokcy
2018-03-29
rendertostring只需要渲染出html,这是一次性的
00
相似问题