saferstringify
saferstringify on export