title: how to send an object from controller to view (Twig) in Symfony 3
body: <p>Imagine that we have the controller <code>AdvertController.php</code> with the edit action <code>public function editAction(Request $request)</code> that sends an object <code>$user</code> to the view <code>edit.html.twig</code>, <code>$user</code> contains many attributes ans methods that return a strings</p>
  
  <pre><code>public function editAction(Request $request){
  $user = new User();
  return $this-&gt;render('OCPlatformBundle:Advert:edit.html.twig', array());
  }
  </code></pre>
  
  <p>What I need to add in the code ? So that in the view I can display the values</p>
  
  <pre><code>edit.html.twig
  
  {{ user.name }}
  </code></pre>