I am building a module with a block that outputs some informations from the current node.
When i return my render array i managed to get the cache as "node dependent" using (maybe not the best method ?) :
'#cache' => [ 'contexts' => [ 'url', ], ],
The blocks are showing up the right contents on the right pages, but if i modify my node and it's fields, the block content remains pulled from the cache and is not updated with the latest values.
Is there anything to add in the #cache array or a way to invalidate this specific cache when node gets updated ?