UtilsWala

Diff Checker

Compare two text, code, or configuration files side-by-side with line-by-line and word-level diff highlighting.

Diff View & Options

Side-by-Side Code & Text Diff Checker

Compare differences between two blocks of text or source code

+5 additions-4 deletions
Original Text (Before)Deletions (-)
1-function calculateTax(amount) {
2- const rate = 0.18;
3- return amount * rate;
4 }
5
6-console.log(calculateTax(100));
Modified Text (After)Additions (+)
1+function calculateTax(amount, customRate = 0.18) {
2+ if (amount <= 0) return 0;
3+ const total = amount * customRate;
4+ return Math.round(total * 100) / 100;
5 }
6
7+console.log("Calculated tax:", calculateTax(100));