MCPcopy
hub / github.com/wellsjo/JSON-Splora / validate

Method validate

app/js/Editor.js:139–147  ·  view source on GitHub ↗

* Validate editor input. Emits 'input-valid' and sets this.data.

()

Source from the content-addressed store, hash-verified

137 */
138
139 validate() {
140 const input = this.editor.getValue()
141 try {
142 this.data = json5.parse(input)
143 this.emit('input-valid')
144 } catch (e) {
145 this.data = null
146 }
147 }
148
149 /**
150 * Set the theme dynamically

Callers 2

handleEventsMethod · 0.95
setValueMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected