Working in three-dimensional XR space might entice you to go fully 3D by adding depth to your text. It might feel the right thing to do but it has severe consequences on its utility.
The depth of text hinders both readability and legibility. It adds to the letter shapes and in certain situations makes the letter unrecognizable. And requires extra effort from the user's side to recognize them. This problem gets amplified if the user is looking at the text from an angle.
Keep 3D text limited to headings or strings of text.
Use 2D text for sentences and paragraphs.
If 3D text is absolutely necessary then adjust the letter-spacing to correctly space them out.
The difference in colour on the face of text vs depth might provide enough contrast to aid easy recognition of text in certain cases.