I think a key point here is to notice that MathML (understand: math on
the Web) is different than LaTeX. In LaTeX you can "tweak" your formula
to be good-looking when you create your pdf or print it. With MathML you
can't assume that what you see on your screen with be the same on, say
mobile terminals or other systems with different math fonts. Thus the
linebreaking design explained by David Carlisle. Your proposal will work
to make one break optional but as you say in other screens one will need
to break elsewhere (like at + operators etc).
The MathML linebreaking (essentially, "breaking at operators") is
implemented in MathJax, but disabled by default. To enable it, add
"HTML-CSS": { linebreaks: { automatic: true } },
"SVG": { linebreaks: { automatic: true } }
to your configuration file. I think what you really want is an option to
recommend a "good break" in the MathML terminology. So when the the
space is narrow, MathJax will try to break at that point in priority. Of
course, if it is still not enough then it will break at other operators too.
I don't think MathJax as TeX command to specify a goodbreak but you can use
\mmlToken{mo}[linebreak="goodbreak"]{=}
to say that the = is a good break (of course, you can define a new macro
for that purpose). I attach screenshots showing how MathJax behaves with
and without this goodbreak.
Hope that helps.