Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Ionic Framework
  3. Masks

Masks

MITTypeScript

An Angular/Ionic 4 input masking library for Brazilian formats like CPF, CNPJ, phone numbers, and currency.

GitHubGitHub
116 stars54 forks0 contributors

What is Masks?

brmasker-ionic is an input masking library for Ionic 4 and Angular applications that formats user input according to Brazilian standards. It provides pre-configured masks for CPF, CNPJ, phone numbers, currency, and percentages, as well as custom mask patterns. The library solves the problem of manually implementing complex input formatting for Brazilian data formats in web and mobile apps.

Target Audience

Developers building Ionic 4 or Angular applications that require Brazilian-specific input formatting, such as financial apps, registration forms, or government-related systems.

Value Proposition

It offers a lightweight, easy-to-integrate solution tailored to Brazilian conventions, saving development time compared to building custom masking logic or using generic international libraries.

Overview

brmasker-ionic is an input masking library designed specifically for Ionic 4 and Angular applications. It provides a directive to format user input in real-time according to common Brazilian conventions, such as CPF/CNPJ, phone numbers, currency, and percentages.

Key Features

  • Brazilian Format Support — Pre-configured masks for CPF, CNPJ, phone numbers (with/without DDD), and Brazilian Real currency.
  • Custom Mask Patterns — Define custom masks using patterns like '00:00' for time or any alphanumeric format.
  • Flexible Configuration — Options for decimal places, thousand separators, and handling user-entered special characters.
  • Directive Integration — Easily apply masks to Ionic input elements via the [brmasker] directive.
  • Programmatic Masking — Use the BrMaskDirective to format values programmatically in TypeScript.

Philosophy

It focuses on simplifying the implementation of Brazilian-specific input formatting in Ionic 4 apps, reducing boilerplate code for developers.

Use Cases

Best For

  • Formatting CPF and CNPJ inputs in Brazilian registration forms
  • Applying phone number masks with and without DDD in contact forms
  • Formatting currency inputs for Brazilian Real with custom decimal places
  • Creating custom input masks for time, dates, or alphanumeric patterns
  • Handling percentage inputs with proper formatting
  • Ensuring consistent data entry in Brazilian Portuguese applications

Not Ideal For

  • Projects using Ionic 5+ or modern Angular versions beyond v6
  • Applications requiring input masking for international formats outside Brazil
  • Teams needing actively maintained libraries with regular updates and bug fixes
  • Large-scale production apps where dependency on deprecated code poses security risks

Pros & Cons

Pros

Brazilian Format Specialization

Includes pre-configured masks for CPF, CNPJ, phone with/without DDD, currency, and percentages, directly addressing Brazilian conventions without custom logic.

Flexible Custom Masks

Supports custom mask patterns like '00:00' for time, with configurable types (alfa/num/all) and user-defined characters, enabling versatile input formatting.

Easy Ionic Integration

Provides a simple [brmasker] directive that can be applied directly to Ionic input elements, reducing boilerplate code for developers.

Programmatic Control

Offers BrMaskDirective for formatting values in TypeScript, allowing dynamic masking and integration with reactive forms.

Cons

Deprecated and Unmaintained

The README explicitly states the project is deprecated with no maintenance, meaning no bug fixes, security updates, or compatibility improvements.

Outdated Dependencies

Requires specific old versions like Node 10.7.0, Ionic 4.1.2, and Angular CLI 6.1.2, which are incompatible with modern development stacks.

Limited Geographic Scope

Focused solely on Brazilian formats, so it lacks support for international masks, making it unsuitable for global applications.

Frequently Asked Questions

Quick Stats

Stars116
Forks54
Contributors0
Open Issues28
Last commit3 years ago
CreatedSince 2018

Tags

#input-masking#currency-formatting#frontend#ionic#form-validation#angular

Built With

I
Ionic 4
A
Angular
T
TypeScript
N
Node.js

Included in

Ionic Framework858
Auto-fetched 19 hours ago

Related Projects

Dynamic FormsDynamic Forms

Rapid form development library for Angular

Stars1,309
Forks369
Last commit2 years ago
SelectableSelectable

Ionic Selectable is an Ionic versatile and highly customizable component that serves as a replacement to Ionic Select, and allows to search items, including async search, create items, customize the layout with templates and much more. It provides an intuitive API and is easy to set up and use.

Stars552
Forks133
Last commit1 year ago
Form Generator based on JSONForm Generator based on JSON

HTML form generation based on JSON Schema

Stars483
Forks171
Last commit21 hours ago
AutocompleteAutocomplete

Ionic 2 autocomplete component

Stars147
Forks106
Last commit2 years ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub