Closed Scrum closed 5 years ago
Can you explain a little more about what you are asking?
Yep :)
If i have input element with value
<input value="41111111">
and initialize restricted-input
const formattedCreditCardInput = new RestrictedInput({
element,
pattern: '{{9999}} {{9999}}'
});
The value in the input is not formatted. A basic strategy was chosen in which the
function BaseStrategy(options) {
this.isFormatted = false;
...
}
and there is no explicit trigger for the value to be formatted
I created a demo for a credit-card-gaps-pattern that creates a pattern for restricted-input
in which you can watch as I clearly trigger call setPattern
to initialize formatting
Having it set the pattern on initialization seems reasonable. Would you like to open a PR?
@crookedneighbor Would you like to open a PR? Yep, in process.
Would you be interested if I transferred to your org credit-card-gaps-pattern ?
@crookedneighbor
Would you like to open a PR?
success #52
No, we do not wish to maintain credit-card-gaps-pattern at this time.
not problem :)
This is out with v2.0.0
What is the sacred meaning not to format at initialization?