Can you create cloze within code block

I’d like to recreate in remnote my learning cards for my coding like how I had in https://mem.dev/. I was able to cloze sections of my code, and then type it out when in recall mode.
In remnote, I find I’m only able to do cloze in regular text but not in code block. This would make it awkward for larger code blocks of more than few lines as it would lose all indenting and colouring.

Am I missing a technique here? Please advice.

Sadly, there is no way to cloze code blocks. You can, however, type everything into a block (to get the syntax highlight), take a snip of it (win+shift+s on windows), paste it as an image and occlude it. Optionally you could use comments to ask questions about parts of the code or snip a few rem with code blocks at a time to maximise real estate. Obviously, this is best for processes rather than specific functions that may need to be linked to/from. For simple inline pieces you can use quote formatting (``) and cloze that.