Remarkably enhanced gas separation by partial self-conversion of a laminated membrane to metal-organic frameworks.