Skip to content

Commit

Permalink
perf: tostring bytecode
Browse files Browse the repository at this point in the history
  • Loading branch information
gurgunday committed Oct 18, 2024
1 parent dce08b7 commit 9cbeaf9
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ export const htmlGenerator = function* (literals, ...expressions) {
continue;
}

string = String(expression);
string = `${expression}`;

if (string.length !== 0) {
if (!isRaw) {
Expand All @@ -134,7 +134,7 @@ export const htmlGenerator = function* (literals, ...expressions) {
continue;
}

string = String(expression);
string = `${expression}`;
}

if (string.length !== 0) {
Expand All @@ -149,7 +149,7 @@ export const htmlGenerator = function* (literals, ...expressions) {
continue;
}

string = String(expression);
string = `${expression}`;
}

if (literal.length !== 0 && literal.charCodeAt(literal.length - 1) === 33) {
Expand Down Expand Up @@ -217,7 +217,7 @@ export const htmlAsyncGenerator = async function* (literals, ...expressions) {
continue;
}

string = String(expression);
string = `${expression}`;

if (string.length !== 0) {
if (!isRaw) {
Expand All @@ -231,7 +231,7 @@ export const htmlAsyncGenerator = async function* (literals, ...expressions) {
continue;
}

string = String(expression);
string = `${expression}`;
}

if (string.length !== 0) {
Expand All @@ -246,7 +246,7 @@ export const htmlAsyncGenerator = async function* (literals, ...expressions) {
continue;
}

string = String(expression);
string = `${expression}`;
}

if (literal.length !== 0 && literal.charCodeAt(literal.length - 1) === 33) {
Expand Down

0 comments on commit 9cbeaf9

Please sign in to comment.