MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / innerMode

Function innerMode

lib/web/CodeMirror/src/modes.js:83–92  ·  view source on GitHub ↗
(mode, state)

Source from the content-addressed store, hash-verified

81// Given a mode and a state (for that mode), find the inner mode and
82// state at the position that the state refers to.
83export function innerMode(mode, state) {
84 let info
85 while (mode.innerMode) {
86 info = mode.innerMode(state)
87 if (!info || info.mode == mode) break
88 state = info.state
89 mode = info.mode
90 }
91 return info || {mode: mode, state: state}
92}
93
94export function startState(mode, a1, a2) {
95 return mode.startState ? mode.startState(a1, a2) : true

Callers 2

callBlankLineFunction · 0.90
readTokenFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected