title: Read array from Firebase in Flutter
body: <p>I have a collection defined in Firebase with different field types, such as Strings and arrays of string. </p>
  
  <p>I am able to read Strings from <code>DocumentSnapshot</code> simply by calling:</p>
  
  <pre><code>String name = document['name'];
  </code></pre>
  
  <p>But how can I get <code>List&lt;String&gt;</code>? By calling </p>
  
  <pre><code>List&lt;String&gt; names1 = document['names'];
  List&lt;String&gt; names2 = document['ingredients'].map((x) =&gt; x.toString())
  </code></pre>
  
  <p>I get following exceptions accordingly:</p>
  
  <blockquote>
    <p>type 'List' is not a subtype of type 'List'<br>
    type 'MappedListIterable' is not a subtype of type 'List'</p>
  </blockquote>