nette/latte

Latte 2 vs Latte 3: <div n:cache="$cacheKey" id="content">

forgie1 opened this issue · 3 comments

Version: 3.0.4

Bug Description

n:cache is not supported in Latte 3?
Here is no comment about this BC break: https://latte.nette.org/en/cookbook/migration-from-latte2 .

Steps To Reproduce

<div n:cache="$cacheKey" id="content">
Results in:

Latte\CompileException
Unexpected attribute n:cache (in

mabar commented

Here is a comment that cache is registered differently if you use Latte independently (of nette/di) https://latte.nette.org/en/cookbook/migration-from-latte2#toc-nette-caching

If you use full Nette, just update other Nette dependencies.

Cache is working just fine, if I use {cache ...} macro.
Problem is only with <div n:cache="....

I tested it actually directly on: https://github.com/nette/web-project so there is not any kind of our project special anything ...

dg commented

Fixed in nette/caching (in the 3.1-dev & 3.2-dev for now)