有两个树枝文件src/MyVendor/MyBundle/Resources/views/MyApp/layout.html.twig和src/MyVendor/MyBundle/Resources/views/MyApp/myView.html.twig。
src/MyVendor/MyBundle/Resources/views/MyApp/myView.html.twig的内容
{% extends "layout.html.twig" %}
{% block content %}
view content is here.
{% endblock %}
但我收到一个错误
Unable to find template "layout.html.twig" in
"MyVendorMyBundle:MyApp:myView.html.twig"