cuelang.org/go@v0.10.1/encoding/jsonschema/testdata/typeexcluded.txtar (about) 1 -- type.json -- 2 { 3 "type": "object", 4 "properties": { 5 "e0": { 6 "type": [ 7 "integer" 8 ], 9 "minimum": 2, 10 "maximum": 3, 11 "maxLength": 5 12 }, 13 "e1": { 14 "enum": [ 15 "cover", 16 "contain" 17 ], 18 "type": [ 19 "array", 20 "boolean", 21 "number", 22 "object", 23 "string", 24 "null" 25 ] 26 }, 27 "e2": { 28 "title": "none", 29 "type": "string", 30 "enum": [ 31 "none" 32 ], 33 "required": [ 34 "none" 35 ] 36 }, 37 "e3": { 38 "type": "array", 39 "uniqueItems": true, 40 "minItems": 1, 41 "items": { 42 "type": "string", 43 "minLength": 1 44 }, 45 "minLength": 1 46 }, 47 "e4": { 48 "type": "array", 49 "description": "Main authors of the plugin", 50 "items": { 51 "type": "string", 52 "uniqueItems": true 53 } 54 }, 55 "e5": { 56 "type": "integer", 57 "minimum": 0 58 }, 59 "e6": { 60 "items": { 61 "type": "string", 62 "pattern": "^[A-Za-z0-9 _.-]+$" 63 }, 64 "type": "array", 65 "pattern": "^[A-Za-z0-9 _.-]+$" 66 }, 67 "e7": { 68 "type": [ 69 "boolean", 70 "object" 71 ], 72 "anyOf": [ 73 { 74 "type": "boolean", 75 "enum": [ 76 true, 77 {} 78 ] 79 }, 80 { 81 "type": "object", 82 "allOf": [ 83 { 84 "properties": { 85 "disableFix": { 86 "type": "boolean" 87 } 88 } 89 } 90 ], 91 "properties": { 92 "ignoreMediaFeatureNames": { 93 "type": "array", 94 "minItems": 1, 95 "uniqueItems": true, 96 "items": { 97 "type": "string" 98 } 99 } 100 } 101 } 102 ] 103 } 104 } 105 } 106 -- out/decode/cue -- 107 import ( 108 "list" 109 "strings" 110 ) 111 112 e0?: int & >=2 & <=3 113 e1?: "cover" | "contain" 114 115 // none 116 e2?: "none" 117 e3?: list.UniqueItems() & [_, ...] & [...strings.MinRunes(1)] 118 119 // Main authors of the plugin 120 e4?: [...string] 121 e5?: int & >=0 122 e6?: [...=~"^[A-Za-z0-9 _.-]+$"] 123 e7?: true | { 124 disableFix?: bool 125 ... 126 } & { 127 ignoreMediaFeatureNames?: list.UniqueItems() & [_, ...] & [...string] 128 ... 129 } 130 ...