There are two questions about the SVG (Scalable Vector Graphics):
1) What is the best JavaScript library used to create vector graphics SVG?
2) Can I then received SVG vector graphics, the browser, export to a PDF file? If so, how can this be accomplished?