MCPcopy Index your code
hub / github.com/bigskysoftware/_hyperscript / parse

Method parse

www/js/_hyperscript.js:5540–5546  ·  view source on GitHub ↗
(parser)

Source from the content-addressed store, hash-verified

5538 this.args = { value: rhs };
5539 }
5540 static parse(parser) {
5541 var op = parser.matchAnyToken("first", "last", "random");
5542 if (!op) return;
5543 parser.matchAnyToken("in", "from", "of");
5544 var rhs = parser.requireElement("unaryExpression");
5545 return new _PositionalExpression(rhs, op.value);
5546 }
5547 resolve(context, { value: rhsVal }) {
5548 if (rhsVal && !Array.isArray(rhsVal)) {
5549 if (rhsVal.children) {

Callers

nothing calls this directly

Calls 2

matchAnyTokenMethod · 0.45
requireElementMethod · 0.45

Tested by

no test coverage detected