[Refactoring] Move `createTypeInfoArray` into front-end.