MCPcopy Create free account
hub / github.com/microsoft/SandDance / _getValue

Function _getValue

docs/app/js/sanddance-app.js:50077–50082  ·  view source on GitHub ↗

Get the value from the given state and props (converting from number to string if needed)

(props, state)

Source from the content-addressed store, hash-verified

50075 return TextFieldBase1;
50076}(_react.Component);
50077/** Get the value from the given state and props (converting from number to string if needed) */ function _getValue(props, state) {
50078 var _a = props.value, value = _a === void 0 ? state.uncontrolledValue : _a;
50079 if (typeof value === "number") // not allowed per typings, but happens anyway
50080 return String(value);
50081 return value;
50082}
50083/**
50084 * If `validateOnFocusIn` or `validateOnFocusOut` is true, validation should run **only** on that event.
50085 * Otherwise, validation should run on every change.

Callers 2

TextFieldBase1Function · 0.85
sanddance-app.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected