Handle both strings and objects in Base.importJson().

And keep returning strings from #exportJson().
Switch back to persistence of segments for good.