Skip to content

Symfony 4 template not found exception #21

@mechanicalgux

Description

@mechanicalgux

This bundle will trigger an exception Symfony 4.

$resources = array_merge(array('StarRatingBundle::rating.html.twig'), $resources);

To solve this, change the line with:

$resources = array_merge(array('@StarRatingBundle/rating.html.twig'), $resources);

Then add and alias to /config/packages/twig.yaml:

twig:
  paths:
    '%kernel.project_dir%/templates': templates
    '%kernel.project_dir%/vendor/blackknight467/star-rating-bundle/blackknight467/StarRatingBundle/Resources/views': StarRatingBundle

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions