assisrafael/angular-input-masks

Dynamic masks

Open

#235 建立於 2016年11月17日

在 GitHub 查看
 (0 留言) (3 反應) (0 負責人)JavaScript (334 fork)batch import
enhancementhelp wanted

倉庫指標

Star
 (970 star)
PR 合併指標
 (30 天內沒有已合併 PR)

描述

Hi,

Given a condition on my controller, I need to change the input masks (ui-money-mask to ui-number-mask) dynamically.

I am doing this way:

<input ng-if="condition" type="text" ui-money-mask />
<input ng-if="!condition" type="text" ui-number-mask />

Is there a better way to do it?

Thanks.

貢獻者指南