File tree Expand file tree Collapse file tree 1 file changed +2
-9
lines changed Expand file tree Collapse file tree 1 file changed +2
-9
lines changed Original file line number Diff line number Diff line change @@ -63,8 +63,8 @@ const checkEscaping = (code, isLiteral) => {
6363 }
6464} ;
6565
66- console . log ( ' │ Literal (dedent`...`) │ Function (dedent(...))' ) ;
67- console . log ( '────────────┼ ───────────────────────┼────────────────────────' ) ;
66+ console . log ( ' │ Literal (dedent`...`) │ Function (dedent(` ...` ))' ) ;
67+ console . log ( '─────────────┼── ───────────────────────┼────────────────────────' ) ;
6868const rolldownLiteral = checkEscaping ( rolldownCode , true ) ;
6969const rolldownFunction = checkEscaping ( rolldownCode , false ) ;
7070const tsdownLiteral = checkEscaping ( tsdownCode , true ) ;
@@ -73,10 +73,3 @@ const tsdownFunction = checkEscaping(tsdownCode, false);
7373console . log ( `Rolldown │ ${ rolldownLiteral . padEnd ( 23 ) } │ ${ rolldownFunction } ` ) ;
7474console . log ( `Tsdown │ ${ tsdownLiteral . padEnd ( 23 ) } │ ${ tsdownFunction } ` ) ;
7575console . log ( '' ) ;
76-
77- console . log ( '💡 CONCLUSION:' ) ;
78- console . log ( '─' . repeat ( 80 ) ) ;
79- console . log (
80- 'When bundlers process tagged template literals (dedent`...`), they may escape </script>'
81- ) ;
82- console . log ( 'Using function call syntax (dedent(...)) avoids this escaping behavior.' ) ;
You can’t perform that action at this time.
0 commit comments