Implements hook_node_prepare().
function datetime_node_prepare(NodeInterface $node) { // Prepare the 'Authored on' date to use datetime. $node->date = new DrupalDateTime($node->created); }