(annotations: Schema.Annotations.Annotations | undefined)
| 918 | } |
| 919 | |
| 920 | function annotationsPortable(annotations: Schema.Annotations.Annotations | undefined) { |
| 921 | if (annotations === undefined) return true |
| 922 | return Object.entries(annotations).every(([key, value]) => { |
| 923 | if ( |
| 924 | ["toCodec", "toCodecJson", "toArbitrary", "toFormatter", "toEquivalence", "~effect/Schema/Class"].includes(key) |
| 925 | ) { |
| 926 | return true |
| 927 | } |
| 928 | if (key === "generation") return generationPortable(value) |
| 929 | return serializable(value) |
| 930 | }) |
| 931 | } |
| 932 | |
| 933 | function serializable(value: unknown): boolean { |
| 934 | if (value === null || ["string", "number", "boolean"].includes(typeof value)) return true |
no test coverage detected