Code Monkey home page Code Monkey logo

twig-sandbox-bundle's People

Contributors

addfs avatar linniksa avatar muxx avatar slashliv avatar u-mulder avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

twig-sandbox-bundle's Issues

how to use twig sandbox bundle?

Hi,

as described in readme file about how to use it, $twig = $this->get('intaro.twig_sandbox.builder')->getSandboxEnvironment();

Here, what is $this? I still don't know how to use it.

It seems to stop globals from using.

At some point I include global in the $twig instance like this:
$finderService = $this->container->get('finder_service');
$twig->addGlobal('finder', $finderService );

When I include
{{ finder.findOne('arg1', 'arg2', 'arg3') }}
it validates but when rendering generates error: Calling "findone" method on a "...EntityFinder" object is not allowed in "__string_template__0edef266c68e7d81a0718ac749a20f41c39c7e65251c3df9aa0e0c970f9166b9" at line 1.

Also even if I include dump function under intaro.twig_sandbox.policy_functions it never allows me to use it when validating.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.