php - Symfony Yaml based routing doesn't work as generated -
i'm following symfony3 intro.
i ran php bin/console generate:controller
, followed prompts, choosing yaml routing because don't comments code.
it generated following:
number: path: /lucky/number defaults: { _controller: appbundle:lucky:number }
and placed src/appbundle/resources/config/routing.yml
this doesn't work. however, copying contents app/config/routing.yml
does.
it seems i'm missing additional config doesn't mention in guide because expects use annotations routes. doesn't mention in docs here under "using other formats" section.
is copying generated route other file right thing do? there alternative step tells find other yaml based routes?
in app/config/routing.yml
can do:
app: resource: '@appbundle/resources/config/routing.yml'
and write inside of appbundle/resources/config/routing.yml
work
Comments
Post a Comment