which it is the recommendation of esri for make histograms and bar charts with js
Here is an example: Census Data
ESRI's DC R&D Center is working on a charting library for web services. FYI - still in beta.
GitHub - Esri/cedar: Charts for ArcGIS GeoServices
Retrieving data ...