There were some hits for my problem but did not answer fully.
I found out the PassOptions... command to get rid of some options clash with url and hyperref packages here
Forcing linebreaks in \url does not work with biblatex and menukeys
I have the below MWE with two options where I am using biblatex.
One is with hyperref and the other without. The one without hyperref works fine and the url information is broken correctly but the one with hyperref does not work. It leaves the link as a one long line with the box. I could not really find a fix for this. What is missing from the implementation with hyperref?
\documentclass[10pt]{article}
% % option 1
% %
% % that works without hyperref
% % and the links I used as in the rest of my thesis
% % the long line is broken correctly without using
% % hyphens option with the url package
% \usepackage[backend=bibtex,backref,style=numeric,
% sorting=nyt,firstinits=true,maxbibnames=99]{biblatex}
% \addbibresource{test.bib}
% \usepackage{xcolor}
% % the test
% \title{Test document}
% \begin{document}
% this\cite{nvh_BK} is a test.
% \printbibliography
% % end of option 1
% option 2
% with hyperref package
% I found out that I have to use the
% PassOptionsToPackage before the biblatex definitions
%
\PassOptionsToPackage{hyphens}{url}
%
\usepackage[backend=bibtex,backref,style=numeric,
sorting=nyt,firstinits=true,maxbibnames=99]{biblatex}
\addbibresource{test.bib}
\usepackage{hyperref}
\usepackage{xcolor}
\hypersetup{
colorlinks = true, % Colours links instead of ugly boxes
urlcolor = blue, % Colour for external hyperlinks
linkcolor = blue, % Colour of internal links
citecolor = red, % Colour of citations
pdfborder = { 0 0 1 }, % Border for pdf
linkbordercolor = blue, % Border color
citebordercolor = red,
breaklinks = true
}
% test
\title{Test document}
\begin{document}
this\cite{nvh_BK} is a test.
\printbibliography
% end of option 2
\end{document}
test bib file I used with one entry is as follows:
@online{nvh_BK,
author = {Bruel\&Kjaer},
title = {Vehicle noise vibration and harshness development},
year = 2019,
url = {https://www.bksv.com/en/Applications/vehicle-noise-vibration-and-harshness-development-test-test-test},
urldate = {2019-05-10}
}
\usepackage{xurl}beforebiblatex– CarLaTeX Jul 27 '19 at 14:03