Passing arbitrary data to nodes or edges

Is there a proposal or ongoing discussion to add a data attribute to Graphviz elements (nodes and edges)?

For example:

digraph G {
  a[data="{m: 1, n: 2}"]
  a -> b[data="{x: 1, y: 2}" class="blah"]

I think you could do this:

digraph G {
a[data-m=“1” data-n=“2”]
a → b [data-x=“1” data-y=“2” class=“blah”]

Graphviz ignores attributes it doesn’t understand. They’ll be preserved during graph processing I think, but they won’t be used by any output format.

Is there a broader goal you’re trying to achieve? That might help come up with ideas.

To be clear, there’s nothing special about “data-”, it’s just an attribute that Graphviz doesn’t do anything with.

In the Before Time, we used to emit some attributes inline with generated code, but I believe there was concern that this would open certain potential exploits, like, draw a graph and it does something unexpected with your .ssh credentials.