I am trying to set up Twig Templating Engine with my new Codeigniter project.
But I am getting this error after setting up
Twig Exception
There are no registered paths for namespace "__main__".
I don't know what this error means. and how to solve it.
As per I am checking this is originated from the following file-
/application/vendor/twig/twig/lib/Twig/Loader/Filesystem.php:
code:
class Twig_Loader_Filesystem implements Twig_LoaderInterface, Twig_ExistsLoaderInterface, Twig_SourceContextLoaderInterface
{
/** Identifier of the main namespace. */
const MAIN_NAMESPACE = '__main__';
protected $paths = array();
protected $cache = array();
protected $errorCache = array();
private $rootPath;
...
I followed this article for setting up
https://github.com/bcit-ci/CodeIgniter/wiki/Twig-PHP-Template-Engine-Implementation
Codeigniter Version- 3.1.8