MCPcopy Index your code
hub / github.com/autoNumeric/autoNumeric / reformat

Method reformat

src/AutoNumeric.js:2598–2603  ·  view source on GitHub ↗

* Force the element to reformat its value again (just in case the formatting has been lost). * This can be used right after a form submission for instance (after a previous call to `unformat`). * * @example anElement.reformat() * * @returns {AutoNumeric}

()

Source from the content-addressed store, hash-verified

2596 * @returns {AutoNumeric}
2597 */
2598 reformat() {
2599 // `this.rawValue` is used instead of `this.domElement.value` because when the content is `unformatLocalized`, it can become a string that cannot be converted to a number easily
2600 this.set(this.rawValue);
2601
2602 return this;
2603 }
2604
2605 /**
2606 * Remove the formatting and keep only the raw unformatted value in the element (as a numericString)

Callers 6

_exitFormulaModeMethod · 0.95
_onKeydownMethod · 0.95
constructorMethod · 0.80
formReformatMethod · 0.80
_reformatAltHoveredMethod · 0.80

Calls 1

setMethod · 0.95

Tested by

no test coverage detected