MCPcopy Index your code
hub / github.com/mobxjs/mobx / assertFlowDescriptor

Function assertFlowDescriptor

packages/mobx/src/types/flowannotation.ts:88–100  ·  view source on GitHub ↗
(
    adm: ObservableObjectAdministration,
    { annotationType_ }: Annotation,
    key: PropertyKey,
    { value }: PropertyDescriptor
)

Source from the content-addressed store, hash-verified

86}
87
88function assertFlowDescriptor(
89 adm: ObservableObjectAdministration,
90 { annotationType_ }: Annotation,
91 key: PropertyKey,
92 { value }: PropertyDescriptor
93) {
94 if (__DEV__ && !isFunction(value)) {
95 die(
96 `Cannot apply '${annotationType_}' to '${adm.name_}.${key.toString()}':` +
97 `\n'${annotationType_}' can only be used on properties with a generator function value.`
98 )
99 }
100}
101
102function createFlowDescriptor(
103 adm: ObservableObjectAdministration,

Callers 1

createFlowDescriptorFunction · 0.85

Calls 3

isFunctionFunction · 0.85
dieFunction · 0.85
toStringMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…