Is your enhancement request related to a problem? Please describe.
Invoking @crafter.breadcrumb prints nothing on to the page. Though it is technically correct, the defaults could be improved to help developers. Particularly when getting started and not having knowledge about the macro. Furthermore, the url argument should probably be contentModel.storeUrl on most usages, so we could set that as default.
Describe the solution you'd like
Adjust url argument of the breadcrumb macro to be contentModel.storeUrl, with proper fallback validation for contentModel and storeUrl not being present.
that it should be a full path to the page, including the index.xml. Because the name of the argument all the way down to the service code is url, it is easy to think of it as a web url such as /, when in reality it is a full path, like /site/website/index.xml
update the default value that's stated
suggest using contentModel.storeUrl to get/use the full path of the current model
to note that if the root == url, the macro doesn't print any breadcrumbs. In practice, this means the home page shows no breadcrumbs and should the breadcrumb item be desired, the root needs to be set to something upwards of the home path (i.e. /site/website) which is the default (e.g. /site)
Latest version
Duplicates
Is your enhancement request related to a problem? Please describe.
Invoking
@crafter.breadcrumb
prints nothing on to the page. Though it is technically correct, the defaults could be improved to help developers. Particularly when getting started and not having knowledge about the macro. Furthermore, theurl
argument should probably becontentModel.storeUrl
on most usages, so we could set that as default.Describe the solution you'd like
url
argument of the breadcrumb macro to becontentModel.storeUrl
, with proper fallback validation forcontentModel
andstoreUrl
not being present.url
,index.xml
. Because the name of the argument all the way down to the service code isurl
, it is easy to think of it as a web url such as/
, when in reality it is a full path, like/site/website/index.xml
contentModel.storeUrl
to get/use the full path of the current model/site/website
) which is the default (e.g./site
)