File tree Expand file tree Collapse file tree 4 files changed +182
-175
lines changed
Benchmarks/Benchmarks/SwiftHTMLKit Expand file tree Collapse file tree 4 files changed +182
-175
lines changed Original file line number Diff line number Diff line change @@ -12,27 +12,27 @@ package struct SwiftHTMLKitTests : HTMLGenerator {
1212 package init ( ) { }
1313
1414 package func staticHTML( ) -> String {
15- #html( [
16- #head( [
17- #title( [ " StaticView " ] )
18- ] ) ,
19- #body( [
20- #h1 ( [ " Swift HTML Benchmarks " ] )
21- ] )
22- ] )
15+ #html(
16+ #head(
17+ #title( " StaticView " )
18+ ) ,
19+ #body(
20+ #h1 ( " Swift HTML Benchmarks " )
21+ )
22+ )
2323 }
2424 package func dynamicHTML( _ context: HTMLContext ) -> String {
25- let qualities : String = context. user. qualities. map ( { #li( [ " \( $0) " ] ) } ) . joined ( )
26- return #html( [
27- #body( [
28- #h1 ( [ " \( context. heading) " ] ) ,
29- #div( attributes: [ . id( context. desc_id) ] , [
30- #p( [ " \( context. string) " ] )
31- ] ) ,
32- #h2 ( [ " \( context. user. details_heading) " ] ) ,
33- #h3 ( [ " \( context. user. qualities_heading) " ] ) ,
34- #ul( attributes: [ . id( context. user. qualities_id) ] , [ " \( qualities) " ] )
35- ] )
36- ] )
25+ let qualities : String = context. user. qualities. map ( { #li( " \( $0) " ) } ) . joined ( )
26+ return #html(
27+ #body(
28+ #h1 ( " \( context. heading) " ) ,
29+ #div( attributes: [ . id( context. desc_id) ] ,
30+ #p( " \( context. string) " )
31+ ) ,
32+ #h2 ( " \( context. user. details_heading) " ) ,
33+ #h3 ( " \( context. user. qualities_heading) " ) ,
34+ #ul( attributes: [ . id( context. user. qualities_id) ] , " \( qualities) " )
35+ )
36+ )
3737 }
3838}
You can’t perform that action at this time.
0 commit comments