[ 
https://issues.apache.org/jira/browse/JSPWIKI-1102?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18040904#comment-18040904
 ] 

Alex O'Ree commented on JSPWIKI-1102:
-------------------------------------

>And even cached files need to be processed by the rendering engine.

True, but we're talking about milliseconds in the browser, and about 40KB of js 
and css to download. Unless you're on a dial up or satcom, this won't matter, 
but fair enough. The webjar is 400k so the distribution would go up slightly.

>The ticket said: "only loaded in pages which require charts" - is that no 
>longer an option?

It still is an option. I can look into the behavior thing and the dynamic 
script injection but i haven't found any documentation on how to add a new 
behavior or how it's integrated. [~brushed] you seemed to be the last 
contributor for related files. Can you provide some insight on this? The public 
wiki has a bit of a gap in this area. See 
[https://jspwiki-wiki.apache.org/Wiki.jsp?page=Haddock%20Template#section-Haddock+Template-HowToExtendTheHaddockTemplate]
 

Pulling from a CDN is really not an option IMO. So if this is merged, it would 
be included it, either via webjars, a plugin or just outright copy and paste 
the resources into the war/src/main/webapp/scripts. The existing PR is webjars 
based, so it would be included in the war and distros and someone manageable 
with maven. Anyone else have a better option?

> Every unnecessary dependency can pull in unnecessary bugs and security leaks.

[~weberjn]  We can say that about many of the ancient 20 year + unmaintained 
dependencies that we currently have too. There's less risk with chartist since 
it's at least somewhat supported than with the existing baggage that we have 
been dragging around. If you think this is an unnecessary change set, let's do 
a vote on the mailing list and put this to rest. 

Still seems like a useful feature to me. In the mean time, i'll to make the 
changes when i have time. If one of you wants to take this over or adjust the 
implementation, please do so. Comment back and i'll let someone else take over.

> Add charting library to JSPWiki distribution
> --------------------------------------------
>
>                 Key: JSPWIKI-1102
>                 URL: https://issues.apache.org/jira/browse/JSPWIKI-1102
>             Project: JSPWiki
>          Issue Type: Improvement
>          Components: Templates and UI
>            Reporter: Dirk Frederickx
>            Assignee: Alex O'Ree
>            Priority: Minor
>         Attachments: image-2025-11-23-14-07-13-571.png
>
>
> Add a charting library to JSPWiki for easy rendering data in TABLE's as line, 
> pie- or bar-charts.
>  The charting library should provide well chosen defaults to keep the extra 
> markup as little as possible.
> Proposal:
>  Include [https://gionkunz.github.io/chartist-js/]  (MIT license) in the 
> standard JSPWiki's distribution.
>  * small footprint  (10K zipped JS; only loaded in pages with require charts)
>  * usage of svg; high quality device independent
>  * highly customizable;  but using 'convention over configuration'  (great 
> defaults)
>  * responsive  (great output on mobile devices)
>  
> Prereq: https://issues.apache.org/jira/browse/JSPWIKI-1040
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to