D8 - How to Get Current node object in content view/edit page

$current_node = \Drupal::routeMatch()->getParameter('node');

Comments

Popular posts from this blog

PHP - How to increase size of POST value in php

D8 KernelEvents constants

D8 - Attach file programmatically to a node