Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow ChartJS custom default font #34

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

noomz
Copy link

@noomz noomz commented Nov 25, 2019

I just added support for custom font via ENV.

@typpo
Copy link
Owner

typpo commented Nov 25, 2019

Thank you Siriwat. I've had problems with using Chartjs globals in the past because the settings would leak and affect other chart renders. I think that may be a problem in this case. We should add a test in test/ci/charts.js to be sure.

@noomz
Copy link
Author

noomz commented Nov 26, 2019

Excuse me, I don't quite get what the problem is. What will it leak and how would it effect the rendering (except for the font). By the way, I will look into the test after my work hours ;)

@typpo
Copy link
Owner

typpo commented Nov 26, 2019

Sorry, I misunderstood. I was imagining and option that allows you to set font color. That could cause problems because the Chart object persists between requests.

However, you've implemented this as an envar, which affects ALL charts anyway, so we don't have to worry about that :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants