Line https://github.com/fkling/JSNetworkX/blob/master/src/drawing/svg.js#L266
the variable is misspelled as weigths whereas the correct code should contain weights in the switch case
I would be happy to send a PR if this project is still maintained ?