Skip to content

Commit

Permalink
style: format code for ESLint best practices
Browse files Browse the repository at this point in the history
  • Loading branch information
souhailtourjmen authored Nov 22, 2024
1 parent 0a4b6d8 commit b85385a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/printer/printHelpers/addTextLine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,14 @@ export async function addTextLine(
PrinterConstants.PRINTER_SETTING_PAPERWIDTH
);

const charsPerLine = customCharsPerLine ? customCharsPerLine :
printerCharsPerLinePerWidth[paperWidth || DEFAULT_PAPER_WIDTH];
const charsPerLine = customCharsPerLine
? customCharsPerLine
: printerCharsPerLinePerWidth[paperWidth || DEFAULT_PAPER_WIDTH];

const text = spaceBetween(
Math.ceil(charsPerLine / printer.currentFontWidth),
params
);

await printer.addText(text);
}

0 comments on commit b85385a

Please sign in to comment.