# Array

### Multiple Value - Array

{% code title="HTML" %}

```markup
<div class="parent">
  <div class="red">Red Text 1</div>
  <div class="red">Red Text 2</div>
  <div class="red">Red Text 3</div>
</div>

```

{% endcode %}

Now let's sum the contents of all the elements with the `red` class. If we are going to collect more than one value, we need to declare it to muninn. Otherwise, it will return the result of the first element it finds.

{% code title="Config" %}

```javascript
{
    "redTexts": {
        "selector": ".red",
        "type": "array"
    }
}

// or use this shortcut

{
    "redTexts": ".red | array"
}
```

{% endcode %}

{% code title="Output" %}

```javascript
{
    "redTexts": [
        "Red Text 1", 
        "Red Text 2", 
        "Red Text 3"
    ] 
}
```

{% endcode %}
