I came across this question about the instances wherein non-breaking space should be used.
For cross-referencing, I am using cleveref. Although its documentation does not indicate anything about non-breaking spaces explicitly, it seems obvious that with cleveref, I no longer need a tie preceding the command \cref{}. Am I right?
I am asking this because, the linters chktex and lacheck integrated with my editor had warned me to introduce a tie. Now, after nearly finishing up the thesis (with the non-breaking spaces) and revisiting the question, it seems to me that this is unnecessary. Also, removal of the non-breaking space will lead to a non-negligible difference in pagination.
What is the general consensus on using non-breaking spaces with cleveref? It does seem to be unnecessary, and might even have placed unnecessary restrictions on the spacing for the box-glue-penalty model. If I have to remove it, is there a quick regex I can run from the command-line?
An obligatory MWE
\documentclass{article}
\usepackage{hyperref}
\usepackage{cleveref}
\begin{document}
See~\cref{sec:massenergy} for more details.
\section{Mass-Energy Relationship}\label{sec:massenergy}
According to blah blah ....
\end{document}


\cref{}macro in any old document. If I have used it, will it hurt? – Dr Krishnakumar Gopalakrishnan Aug 21 '18 at 13:53cleveref, and yet some of us can solve issues with packages we don't regularly use. Without code, you limit your pool of available help to those who already knowcleveref– Steven B. Segletes Aug 21 '18 at 13:54cleverefin their workflow. – Dr Krishnakumar Gopalakrishnan Aug 21 '18 at 13:55\crefinserts not just a1but aSection 1, I would agree that no non-breaking space is needed before it. While one would not want a linebreak between "Section" and "1", I see no readability issue whatsoever with a linebreak before "Section." – Steven B. Segletes Aug 21 '18 at 14:02regexto strip this out for every instance of~preceding\crefor\crefrange? I have hundreds of such instances in my thesis. – Dr Krishnakumar Gopalakrishnan Aug 21 '18 at 14:04vim, but it does not have a native project-level search and replace as far as I am aware. I guess this second part of the question is actually out of the scope of this forum. So, I think I shall consider that this question has been fully answered. If you move your comment to an answer, I shall mark as accepted. – Dr Krishnakumar Gopalakrishnan Aug 21 '18 at 14:09