diff --git a/src/compiler/compile/render_ssr/handlers/Element.ts b/src/compiler/compile/render_ssr/handlers/Element.ts index e33ca9ea56..fb3b69fa02 100644 --- a/src/compiler/compile/render_ssr/handlers/Element.ts +++ b/src/compiler/compile/render_ssr/handlers/Element.ts @@ -124,7 +124,7 @@ export default function(node: Element, renderer: Renderer, options: RenderOption node_contents = x`${snippet} || ""`; } else { const snippet = expression.node; - renderer.add_expression(x`@add_attribute("${name}", ${snippet}, 0)`); + renderer.add_expression(x`@add_attribute("${name}", ${snippet}, ${boolean_attributes.has(name) ? 1 : 0})`); } }); diff --git a/test/runtime/samples/binding-input-checkbox-deep-contextual-b/_config.js b/test/runtime/samples/binding-input-checkbox-deep-contextual-b/_config.js index a4c9dacb6e..eeddaf9981 100644 --- a/test/runtime/samples/binding-input-checkbox-deep-contextual-b/_config.js +++ b/test/runtime/samples/binding-input-checkbox-deep-contextual-b/_config.js @@ -11,18 +11,6 @@ export default { `, - ssrHtml: ` -
one
-two
-three
-one
two
+two
three
+three
1 completed
`, diff --git a/test/runtime/samples/binding-input-checkbox-with-event-in-each/_config.js b/test/runtime/samples/binding-input-checkbox-with-event-in-each/_config.js index 1ce561647f..b502ed40af 100644 --- a/test/runtime/samples/binding-input-checkbox-with-event-in-each/_config.js +++ b/test/runtime/samples/binding-input-checkbox-with-event-in-each/_config.js @@ -17,11 +17,6 @@ export default { `, - ssrHtml: ` - - - `, - test({ assert, component, target, window }) { const { cats } = component; const newCats = cats.slice(); diff --git a/test/runtime/samples/binding-input-text-contextual-reactive/_config.js b/test/runtime/samples/binding-input-text-contextual-reactive/_config.js index 91f243a8b6..6fdfc4be52 100644 --- a/test/runtime/samples/binding-input-text-contextual-reactive/_config.js +++ b/test/runtime/samples/binding-input-text-contextual-reactive/_config.js @@ -26,7 +26,7 @@ export default { ssrHtml: `one
two
three