Comments (5)
Works great for my LineChart component, tested with the same CSP header in Chrome 55 and Firefox 50.
Thanks for fixing that so fast.
from vue-chartjs.
Should be fixed now in v2.3.1
Would be great if you could test it.
from vue-chartjs.
Hi @syxolk ,
well this is not really a bug in vue-chartjs
.
With vue 2 there was a split into a runtime-only and standalone build. The standalone build got the template compiler included, which is needed for the template
function / option.
If you're using *.vue files you can also use the runetime-only build because all template
options get compiled into render
functions. However I am utilizing the extend
functions of vue and the base charts are *.js files.
That is why vue-chartjs
is using the standalone build of vue. (alias for vue.common.js is set in webpack.conf)
Generally there is no issue with that, however if you are in a CSP environment like chrome apps the standalone build will not work.
https://vuejs.org/v2/guide/installation.html#CSP-environments
The only way to get around, would be to use render functions in the base charts instead template.
I will see if I can rewrite it on the weekend.
from vue-chartjs.
Thanks for your quick answer.
I'm using the runtime-only build of vue and precompile my *.vue files with webpack/vue-loader. Therefore I added a restrictive CSP header that disallows eval
. It's a pity that vue-chartjs relies on the standalone build of vue.
Would be really nice if you can make it work with the runtime-only build as well.
However, I don't want to spoil your Christmas Eve 🎄 Enjoy your holidays 😄
from vue-chartjs.
Hey,
well its not a big deal I pushed the rewrite to https://github.com/apertureless/vue-chartjs/tree/feature/runtimebuild
Need only to rewrite the tests a bit and replace the template option with the render function. And do some testing in external projects, go be sure that I didn't break anything.
from vue-chartjs.
Related Issues (20)
- Standalone page support HOT 1
- [Bug]: Read only issue while using vue-query HOT 3
- [Bug]: Reactive Data on Line Chart : can update a single value, cannot update the entire array
- [Bug]: Options (parsing) not updating chart as expected HOT 1
- [Bug]: Error with package version HOT 2
- Mixed chart types support HOT 5
- [Bug]: vue-tsc reports type errors
- [Bug]: Rendering a chart with multiple y axes will display both datasets on the larger scale HOT 1
- [Bug]: Line data point can be of type string when using a timescale HOT 1
- different behaviour between chrome and firefox with same dataset
- [Bug]: Wrong typings for Bar component HOT 7
- a11y: support ARIA attributes, role and fallback content for canvas
- [Bug]: Incorrect animation on data change on two or more datasets in doughnut chart
- [Bug]: Tooltip references invalid element after chart data updates HOT 2
- [Bug]: Fill property is ignored in Line Chart HOT 1
- [Bug]: Dynamically updating a chart HOT 5
- [Bug]: Error: "category" is not a registered scale. HOT 1
- Seems like there is no way to use chartjs-gauge library with vue-chartjs. Is there a workaround? HOT 2
- [Bug]: Problem using vue-chartjs when imported as ESM module
- [Bug]: Type error for `Line` `options` with `chartjs-zoom-plugin`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vue-chartjs.