use toJSON for saving and export
0.4.0