I have a custom block i want only that block's cache to be cleared
I tried 2 methods
- set cachable = false in layout file for my block (This clears full page cache)
- in my block I added a method
public function getCacheLifetime()
{
return false;
}
This also clears the cache of all the blocks available for that layout (i.e clears full page cache).
Is there any way to just make my block uncacheable?