tessl install tessl/npm-acorn-jsx@5.3.0JSX parsing plugin for the Acorn JavaScript parser that enables fast parsing of React JSX syntax
Agent Success
Agent success rate when using this tile
76%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.69x
Baseline
Agent success rate without this tile
45%
Build a tool that inspects the internal token contexts used by the JSX parser as it processes code.
Create a function that:
Token contexts represent the internal state of the parser as it processes different syntactic elements. Your implementation should:
Return an array of objects with:
name: The identifier of the token contextdescription: A brief description of what the context is used forWhen parsing JSX code "<Component />":
name property (string) and a description property (string)When parsing JSX code "<div>text</div>":
@generates
/**
* Inspects available token contexts from the JSX parser.
*
* @param {string} jsxCode - JSX code to trigger parser initialization
* @returns {Array<{name: string, description: string}>} Array of token context definitions
*/
function getTokenContexts(jsxCode) {
// IMPLEMENTATION HERE
}
module.exports = { getTokenContexts };Provides the core JavaScript parser.
Provides JSX parsing capabilities with token context management.