The Tikz Quotes Library provides a convenient means of drawing labeled edges between nodes. However, I have encountered a problem when the edge label has a comma in it. Given below is a MWE of the problem. The comma between x and y in the edge drawing statement causes the code not to compile. The code compiles when the comma is removed.
I would appreciate any help with the resolution of the comma issue.
\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary{positioning,quotes}
\begin{document}
\begin{tikzpicture}
\node (A) at (0,0) {$x$};
\node (B) [right = 2cm of A] {$y$};
\draw[-latex] (A) edge ["$\left(x,y\right)$"] (B);
\end{tikzpicture}
\end{document}
[
and]
, probably. You have to hide them from the option parser with a group, as shown by @Οὖτις (checked, it works here.)