privatize component_templates method, simplify prefixes impl