title: Create custom child node with RABL
body: <p>I'd like to create JSON like this:</p>
  
  <pre><code>{
    "field1": "value-1",
    "field2": "value-2",
    "actions": {
      "edit": "/edit/action/url"
    }
  }
  </code></pre>
  
  <p>using rabl. It doesn't work with <code>child</code> method nor i can't do it with <code>node</code> - got unknown method error. So, is it possible to create custom child node using rabl template? Say something like this:</p>
  
  <pre><code>collection @datas =&gt; :datas
  attributes :field1, :field2
  child :actions do
    node :edit do
      edit_datas_path :id
    end
  end
  </code></pre>
  
  <p><em><strong>edit</em></strong><br>
  I choose this one:</p>
  
  <pre><code>node :actions do
    actions = {}
    actions[:edit] = edit_customer_group_path(:id)
    node :foo do
      foos = {}
      foos[:bar] = "hello"
      foos
    end
    actions
  end
  </code></pre>
  
  <p>But accepted answer below is correct too.</p>