TransWikia.com

Overleaf keeps complaining when math mode is defined inside newcommand

TeX - LaTeX Asked by iliTheFallen on January 5, 2021

I have a perfect newcommand as follows:

newcommand{inPlaceEq}[1]{
    scalebox{0.86}{ensuremath{#1}}
}

Even though it compiles and works out perfectly, the editor(overleaf) keeps complaining about the following piece of instructions:

inPlaceEq{P(theta|mathcal{D})}

Saying: "theta must be inside math mode". It is just annoying, except that it works. How can I resolve this weird editor-related issue?

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP