exercise in building js apps, to paint a canvas and save that painting into db