Pearson's principle inspired generalized strategy for the fabrication of metal hydroxide and oxide nanocages.