drawYAxis method
designs the y axis canvas: is the object we are going to draw size: is the size of the area where we are going to draw the function return an int value in where will start building the markers of this axis
Implementation
List<int> drawYAxis(Canvas canvas, Size size) {
double x1 = 30;
double x2 = 30;
double y1 = 10;
double y2 = size.height - 10;
final p1 = Offset(x1, y1);
final p2 = Offset(x2, y2);
final paint = Paint()
..color = Colors.black
..style = PaintingStyle.stroke
..strokeWidth = 1;
canvas.drawLine(p1, p2, paint);
return [x1.toInt() - 10, x2.toInt() - 10];
}