Remap a type to flatten the first tier but keep the same structure of every tier after that

Advertisements Given the below code: // Given interface Original { a: { aa: boolean ab: boolean ac: { cat: ‘cat’ } } b: { ba: boolean bb: boolean bc: { dog: ‘dog’ } } } // I want to remap to this interface Remapped { aa: boolean ab: boolean ac: { cat: ‘cat’ } ba:… Read More Remap a type to flatten the first tier but keep the same structure of every tier after that