Merge pull request #1350 from sveltejs/v2-ssr-computed

fix computed properties in SSR mode with v2 syntax
pull/1355/head
Rich Harris 7 years ago committed by GitHub
commit c9ec1559ac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -139,7 +139,7 @@ export default function ssr(
${computations.map(
({ key, deps }) =>
`state.${key} = %computed-${key}(${deps.map(dep => `state.${dep}`).join(', ')});`
`state.${key} = %computed-${key}(${generator.v2 ? 'state' : deps.map(dep => `state.${dep}`).join(', ')});`
)}
${generator.bindings.length &&

Loading…
Cancel
Save