Including delimeters from inner multiplexed mode to outer mode

Hi,

Is it possible in Codemirror v5 (or in v6) to include the delimiters that detect the inner mode, as part of the outer mode?
Example

python_var = function('<html> </html>')

In this case, the outer mode is python because the main code is written in python. I want to achieve a state where the inner string is highlight as html. I defined a multiplexed mode where the start regex is ‘function(’’ and the and regex is ‘"’)", parseDelimiters is false, so the inner string is recognized as html as expected. The issue im having, is that those delimiters should be kept in the python mode, so “function” will still be highlighted as python code, and not be ignored.

Is that possible? Thanks!

I don’t think so. There’s only the parseDelimiters option to make the inner mode parse them.