PackageTrack
Sign in Get early access

nystudio107/craft-twig-sandbox

Allows you to easily create a sandboxed Twig environment where you can control what tags, filters, functions, and object methods/properties are allowed

5.0.5 596K downloads/mo #3627 most downloaded on Packagist nystudio107/craft-twig-sandbox

What this package is like to depend on

Last release 1 years ago

18 Aug 2025

Ships fairly regularly

a new release about every 3 months

Most releases are documented

notes for 13 of 16 stable releases

Nothing withdrawn

no release was ever pulled

2 years old

16 releases · first in 2024

0 releases in the last 12 months

see the full history below

Release timeline

16 releases · Jul 2024 to Aug 2025
2025 2026
Release Pre-release

Releases

latest 16
  1. 5.0.5 18 Aug 2025
    Release notes

    Added

    • Provide a mechanism for adding Twig Extensions in bulk to the SandboxView (#1632)
    Open source →
    Release notes

    Added

    • Provide a mechanism for adding Twig Extensions in bulk to the SandboxView (#1632)
    Open source →
  2. 5.0.4 10 Jun 2025
    Release notes

    Fixed

    • Remove errant dependency on SEOmatic in the SecurityPolicy helper class
    Open source →
    Release notes

    Fixed

    • Remove errant dependency on SEOmatic in the SecurityPolicy helper class
    Open source →
  3. 5.0.3 08 Jun 2025
    Release notes

    Added

    • Add an example config/blacklist-sandbox.php and config/whitelist-sandbox.php files for user-customizable Twig sandbox environments
    • Add SecurityPolicy::createFromFile() to create a new Twig sandbox from a config file in the config/ directory

    Changed

    • Cleaned up the BlacklistSecurityPolicy to no longer blacklist innocuous tags/filters/functions
    Open source →
    Release notes

    Added

    • Add an example config/blacklist-sandbox.php and config/whitelist-sandbox.php files for user-customizable Twig sandbox environments
    • Add SecurityPolicy::createFromFile() to create a new Twig sandbox from a config file in the config/ directory

    Changed

    • Cleaned up the BlacklistSecurityPolicy to no longer blacklist innocuous tags/filters/functions
    Open source →
  4. 5.0.2 18 Feb 2025
    Release notes

    Added

    • Craft Twig Sandbox no longer automatically handles exceptions when rendering sandbox templates. Instead, you can decide whether to handle the exception yourself, or pass it along to the sandboxErrorHandler for display in the browser/console

    Changed

    • Use the official markhuot/craft-pest-core:^2.0.4 package instead of the patch version from @bencroker
    Open source →
  5. 5.0.1 31 Jul 2024
    Release notes

    Changed

    • Removed the special-casing for the Craft Closure, since it now uses a different loading mechanism
    • Simplify the SanboxView to use ::registerTwigExtension rather than overriding ::createTwig()
    Open source →
  6. 5.0.0 03 Jul 2024
    Release notes

    Added

    • Initial release
    Open source →
  7. 4.0.5 18 Aug 2025
    Release notes

    Added

    • Provide a mechanism for adding Twig Extensions in bulk to the SandboxView (#1632)
    Open source →
  8. 4.0.4 10 Jun 2025
    Release notes

    Fixed

    • Remove errant dependency on SEOmatic in the SecurityPolicy helper class
    Open source →
  9. 4.0.3 08 Jun 2025
    Release notes

    Added

    • Add an example config/blacklist-sandbox.php and config/whitelist-sandbox.php files for user-customizable Twig sandbox environments
    • Add SecurityPolicy::createFromFile() to create a new Twig sandbox from a config file in the config/ directory

    Changed

    • Cleaned up the BlacklistSecurityPolicy to no longer blacklist innocuous tags/filters/functions
    Open source →
  10. 4.0.2 18 Feb 2025

    Nothing published for this version

  11. 4.0.1 31 Jul 2024

    Nothing published for this version

  12. 4.0.0 03 Jul 2024

    Nothing published for this version

  13. 3.0.6 18 Aug 2025
    Release notes

    Added

    • Provide a mechanism for adding Twig Extensions in bulk to the SandboxView (#1632)
    Open source →
  14. 3.0.5 11 Jun 2025
    Release notes

    Fixed

    • Fixed an issue with PHP versions less than 7.4 and the SandboxView class (#1614)
    Open source →
  15. 3.0.4 10 Jun 2025
    Release notes

    Fixed

    • Remove errant dependency on SEOmatic in the SecurityPolicy helper class
    Open source →
  16. 3.0.3 09 Jun 2025
    Release notes

    Added

    • Initial release
    Open source →

Every package, every release, already written down.

The archive is open and free. Watching your own project is what we are building next.

Browse the archive