I am new to prose mirror, i have added promise mirror editor to my website.
when user type a code in editor its generating paragraph tag instead of pre tag (see the screen shot below)
So when user preview the editor content it looks like
You provide terribly little information here about what you are actually doing, but one possible thing that might be happening is that your parse rule for paragraph nodes is matching these elements and has a higher precedence than your rule for code blocks.