Skip to content

Instantly share code, notes, and snippets.

@Thanaporn-sk
Last active August 14, 2016 15:43
Show Gist options
  • Save Thanaporn-sk/f060f1df6f5965ee4c40ef242d19f0b5 to your computer and use it in GitHub Desktop.
Save Thanaporn-sk/f060f1df6f5965ee4c40ef242d19f0b5 to your computer and use it in GitHub Desktop.
note test django-nvd3
error : :
TypeError: chart.tooltipContent is not a function
---------------------------------------------------
why?
# deprecate function for newer version dependencies.
my environment
---------------------
django v1.10
nvd3 v 1.8.1
d3 v 4.2.0
django-nvd3 v 0.9.7
---------------------
solution
---------------------
1. uninstall nvd3 and d3
2. install nvd3 version 1.7.1 ( d3#3.3.13 )
bower install nvd3#1.7.1
ps. tracking in demoproject
@Thanaporn-sk
Copy link
Author

http://stackoverflow.com/questions/35125110/django-nvd3-chart-tooltipcontent-is-not-a-function

down vote

To add up on cakan's answer and also to be specific. You need to edit these files by replacing 'chart.tooltipContent' with 'chart.tooltip.contentGenerator' on the corresponding line on the 'nvd3' module at the python site-packages.

1.) pythonx.x/site-packages/nvd3/templates/content.html at line '54' and '63'

2.) pythonx.x/site-packages/nvd3/templates/piechart.html at line '18'

@Thanaporn-sk
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment