private function hydrateComponentsNode(NodeBuilder $node)
    {
        $node
            ->scalarNode('path')->end()
            ->scalarNode('controller')->end()
            ->arrayNode('config')
                ->useAttributeAsKey('name')
                ->prototype('array')
                    ->useAttributeAsKey('name')
                    ->beforeNormalization()
                        ->always(function ($v) {
                            if (is_bool($v)) {
                                return array('enabled' => $v);
                            }

                            return $v;
                        })
                    ->end()
                    ->prototype('scalar')->end()
                ->end()
            ->end()
        ;

        return $node;
    }