Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NFR] Allow \Phalcon\Mvc\View\Engine\Volt to accept Phalcon\Mvc\View\Engine\Volt\Compiler in the constructor #274

Open
dschissler opened this issue Aug 13, 2014 · 2 comments
Labels
new feature request Planned Feature or New Feature Request

Comments

@dschissler
Copy link

If would be nice if \Phalcon\Mvc\View\Engine\Volt could accept a Compiler in the constructor. This would be helpful when using the CLI interface to precompile every Volt view. As it currently stands it doesn't appear that I can use the Volt Compiler in a DI container and so I need to require() Volt configuration code in each place that I want to use the compiler.

Examples of what I need to currently do:

Web:

$compiler = $volt->getCompiler();
require($config->application->phalconDir . '/config/volt_compiler.php');

CLI:

$compiler = new Compiler();
require($config->application->phalconDir . '/config/volt_compiler.php');

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@phalcon phalcon changed the title [NFR] Allow \Phalcon\Mvc\View\Engine\Volt to accept Phalcon\Mvc\View\Engine\Volt\Compiler in the constructor [NFR] Allow \Phalcon\Mvc\View\Engine\Volt to accept Phalcon\Mvc\View\Engine\Volt\Compiler in the constructor Sep 10, 2014
@stale stale bot added the stale Stale issue scheduled to be deleted label Apr 16, 2018
@sergeyklay sergeyklay reopened this May 2, 2018
@stale stale bot removed the stale Stale issue scheduled to be deleted label May 2, 2018
@phalcon phalcon deleted a comment from stale bot Feb 23, 2019
@niden
Copy link
Sponsor Member

niden commented Feb 23, 2019

Closing in favor of phalcon/cphalcon#13855. Will revisit if the community votes for it, or in later versions.

@niden niden closed this as completed Feb 23, 2019
@niden niden added the new feature request Planned Feature or New Feature Request label Dec 9, 2019
@Jeckerson Jeckerson reopened this Mar 30, 2021
@niden niden transferred this issue from phalcon/cphalcon Oct 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature request Planned Feature or New Feature Request
Projects
None yet
Development

No branches or pull requests

4 participants