MCPcopy Index your code
hub / github.com/scriptscat/scriptcat / valueType

Function valueType

src/pkg/utils/utils.ts:47–57  ·  view source on GitHub ↗
(val: unknown)

Source from the content-addressed store, hash-verified

45}
46
47export function valueType(val: unknown) {
48 switch (typeof val) {
49 case "string":
50 case "number":
51 case "boolean":
52 case "object":
53 return typeof val;
54 default:
55 return "unknown";
56 }
57}
58
59export function toStorageValueStr(val: unknown): string {
60 switch (typeof val) {

Callers 2

renderFunction · 0.90
ScriptStorageFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected