Custom parsers not installed in specified order?

I was tinkering with some simple LaTeX extensions and found that the before option doesn’t seem to have any effect on the parsing order. I have the following code:

const BlockLatex = {
    defineNodes: [...],
    parseBlock: [{
        name: "LatexParser",
        parse(cx, line) {
            return false;
    before: "FencedCode"

When inspecting the JS console, this skips all lines associated with fenced code. Then, to verify that the lines were consumed by the fenced code parser, I edited the function isFencedCode() in editor.bundle.js to always return False; after this change, the lines were not skipped (ie. they would be parsed by my parser).

Am I misunderstanding the function of before or is this a bug? In any case, is there a workaround?

It looks like you are putting the before in the wrong place. It should be on the block parser object itself—the one that has the parse method.

That did it, cheers!