openmeteo / enhydris

A database with a web interface for the storage and management of hydro/meteorological measurements and time series
GNU Affero General Public License v3.0
18 stars 11 forks source link

Refactor the chart.js code #400

Closed eyobofficial closed 3 years ago

eyobofficial commented 3 years ago

Closes #389

codecov[bot] commented 3 years ago

Codecov Report

Merging #400 (a867382) into master (ef38e91) will not change coverage. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #400   +/-   ##
=======================================
  Coverage   97.78%   97.78%           
=======================================
  Files          20       20           
  Lines        1447     1447           
=======================================
  Hits         1415     1415           
  Misses         32       32           

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update ef38e91...a867382. Read the comment docs.

aptiko commented 3 years ago

@eyobofficial I have one remark on your code, which I thought was too minor so I merged it anyway. At some point you have const self = this. Now, as you know, I'm not really an expert in JS, but I think that the custom is to use const that = this, that is, use the name that, not self. I'm not really certain. I've definitely seen a book use that (I don't remember which), but I've never seen self.