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

Version 2.8.0 #6092

Merged
merged 137 commits into from
Mar 14, 2019
Merged

Version 2.8.0 #6092

merged 137 commits into from
Mar 14, 2019

Conversation

simonbrunel
Copy link
Member

@simonbrunel simonbrunel commented Feb 25, 2019

Milestone: 2.8
Merged PRs: 133

Please help in testing this upcoming release!

npm install chart.js@2.8.0-rc.1

or download files from the GitHub release.

Checklist:

See the release process for details.

Niladri24dutta and others added 30 commits October 16, 2018 23:12
JSON doesn't support functions which are needed to create scriptable options, so implement a very basic method to load a JavaScript file exporting the config in `module.exports`. Also rename test sources (remove the `jasmine.` prefix), cleanup `karma.conf.js` and add an example .js fixture config (bubble radius option).
In commit c216c0a, the task unittestWatch was removed. However, the watch task links to it, when executed with the test flag. As watching the unittest is possible with `gulp unittest --watch`, this code is not needed anymore and thus removed.
The bar `backgroundColor`, `borderColor`, `borderWidth` and `borderSkipped` options are now scriptable (unit tests, docs and a basic sample). Also fix the gulp task that generates the documentation on Windows.
Use a simpler phrase for this heading.
When the axis lineWidth setting is set to an array, use the first item when determining the size of the axis area.
Moved drawing of radial lines before drawing the tick labels, such that the radial lines are not drawn on top of the tick labels and their backdrop.
Return all items that are at the nearest distance to the point and add unit tests for nearest + axis: 'x' and nearest + axis: 'y'
- Calculate the vertices of the shapes so that they are inscribed in the circle that has the radius of `pointRadius`
- Remove `translate()` and `rotate()` to fix the regression introduced by #5319
- Refactor `rectRounded` for better performance
@spoon252
Copy link

spoon252 commented Mar 7, 2019

@spoon252 It would be more useful to tell us what errors exactly?

Ok, I took the copy of my project and tested it out - works well with 2.7.3.
Using "npm install chart.js@2.8.0-rc.1" I have installed it into the project. All went well. Just running the project again and it fails to create charts. Chrome gives this error:

ERROR TypeError: chart_js__WEBPACK_IMPORTED_MODULE_2__.Chart is not a constructor at LpoComponent.push../src/app/lpo/lpo.component.ts.LpoComponent.createPowerChart (lpo.component.ts:125) at LpoComponent.push../src/app/lpo/lpo.component.ts.LpoComponent.ngOnInit (lpo.component.ts:119) at checkAndUpdateDirectiveInline (core.js:18620) at checkAndUpdateNodeInline (core.js:19884) at checkAndUpdateNode (core.js:19846) at debugCheckAndUpdateNode (core.js:20480) at debugCheckDirectivesFn (core.js:20440) at Object.eval [as updateDirectives] (LpoComponent_Host.ngfactory.js? [sm]:1) at Object.debugUpdateDirectives [as updateDirectives] (core.js:20432) at checkAndUpdateView (core.js:19828)

This is the code for creating the chart
this.PowerChart = new Chart('powerChart', { type: 'line', data: { labels: this.powerchartMeasurementsX, datasets: [{ data: this.powerchartMeasurementsY, fill: false, lineTension: 0.2, borderColor: "black", borderWidth: 2.5, }] }, maintainAspectRatio: false, responsive: true, options: { etc etc
It worked well before the update. Now, I have noticed some weird things happening after npm install.
Chart.js folder inside node_modules after update has "dist" folder only. Original one had "src" folder as well as others. Not sure if this could be an npm or project issue, i will try 2.8.0 on a new project today to see how it works.
I had started to learn angular and js only a couple of months back so excuse for any stupid questions.

@simonbrunel
Copy link
Member Author

I think it's related to #6112 (not released) but you should use import Chart from 'chart.js'; instead.

@simonbrunel
Copy link
Member Author

simonbrunel commented Mar 7, 2019

... has "dist" folder only. Original one had "src" folder ...

That's intended, we don't ship our sources anymore, see #6105 (comment).

@spoon252
Copy link

spoon252 commented Mar 7, 2019

Thanks, import Chart from 'chart.js'; solved that one.

@spoon252
Copy link

spoon252 commented Mar 7, 2019

I think it's related to #6112 (not released) but you should use import Chart from 'chart.js'; instead.

Sorry for bothering, but do i need to change anything regarding to "zoom plugin", it doesn't work with 2.8.0?

@simonbrunel
Copy link
Member Author

It "should" work, can you join our Slack to get support on this update?

Starmordar and others added 3 commits March 11, 2019 09:06
Instead of a direct link, restore the extensions.md file which now redirects /notes/extensions.html to https://github.com/chartjs/awesome in case anyone bookmarked it / there were links to it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.