calculator-app-main

Frontend Mentor - Calculator app solution

This is a solution to the Calculator app challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.

Table of contents

Overview

The challenge

Users should be able to:

Screenshots

My process

Built with

What I learned

I learned a lot about RegExp and TypeScript.

A great example would be this function that checks the passed string and returns a modified version of it with , as thousand separator and . as a decimal separator.

function formatString(value) {
    return value.replace(/\B(?<!\.\d*)(?=(\d{3})+(?!\d))/g, ",");
}

Continued development

I’d definitely plan to get better at writing JavaScript and TypeScript code.

Useful resources

Author