Update src/runtime/internal/ssr.ts

Co-authored-by: Conduitry <git@chor.date>
pull/5701/head
Rich Harris 5 years ago committed by GitHub
parent 29d4695fc7
commit 3a94f2aca5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -144,7 +144,7 @@ export function create_ssr_component(fn) {
export function add_attribute(name, value, boolean) {
if (value == null || (boolean && !value)) return '';
return ` ${name}${value === true ? '' : `=${typeof value === 'string' ? JSON.stringify(escape(value, 1)) : `"${value}"`}`}`;
return ` ${name}${value === true ? '' : `=${typeof value === 'string' ? JSON.stringify(escape(value, true)) : `"${value}"`}`}`;
}
export function add_classes(classes) {

Loading…
Cancel
Save