MCPcopy Create free account
hub / github.com/krasimir/react-in-patterns / getSafeValue

Function getSafeValue

code/new-context-api/public/app.js:4019–4031  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

4017}
4018
4019function getSafeValue(value) {
4020 switch (typeof value) {
4021 case 'boolean':
4022 case 'number':
4023 case 'object':
4024 case 'string':
4025 case 'undefined':
4026 return value;
4027 default:
4028 // function, symbol are assigned as empty strings
4029 return '';
4030 }
4031}
4032
4033var eventTypes$1 = {
4034 change: {

Callers 2

initWrapperStateFunction · 0.70
updateWrapperFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected