I am using angular nvd3 chart for plotting data on charts. I need to export my chart as pdf/png. tried with jdPDF. But It is not rendering css. Can anyone help me out this?
            Asked
            
        
        
            Active
            
        
            Viewed 1,578 times
        
    0
            
            
        - 
                    add the code which you have tried – Aravind Dec 26 '16 at 05:39
 - 
                    nvd3 is wrapper over d3. Possible duplicate of http://stackoverflow.com/questions/16049538/how-to-convert-save-d3-js-graph-to-pdf-jpeg – sandyJoshi Dec 27 '16 at 06:35
 
1 Answers
0
            
            
        Nvd3 does not come with export functionality. There are three ways which you can do,
(i) Conver the element into SVG, send SVG to Server , convert it to PNG and generate link to download using PhantomJS
(ii) Convert SVG to html5 canvas , then convert canvas to PNG and download it using saveSvgAsPng
        Sajeetharan
        
- 216,225
 - 63
 - 350
 - 396
 
- 
                    Although you have said there are 3 ways. Only two are mentioned. I prefer using DigInEngine to do this, which has well optimized codes. https://github.com/DuoSoftware/DigInEngine – Marlon Abeykoon Dec 26 '16 at 06:16