我在 treeBuilder 中创建了一个新根:
class Configuration implements ConfigurationInterface
{
public function getConfigTreeBuilder()
{
$apiNode = $treeBuilder->root('nieuwname');
$apiNode
->children()
->scalarNode('test')
->isRequired()
->end();
}
}
然后我得到下一个异常:
The child node "test" at path "nieuwname" must be configured.
Oke听起来不错。
# config.yml
nieuwname:
test: "test"
然后我得到一个例外:
There is no extension able to load the configuration for "nieuwname"
我做错了什么?