I have this code that hides a div that only contains a specific word, I've been trying (with no luck) to hide any div that contains this word, but also contains more text. 

Any help will be appreciated, thanks! 

```js
let divs = document.getElementsByClassName('test');

for (let x = 0; x < divs.length; x++) {
    let div = divs[x];
    let content = div.innerHTML.trim();

    if (content == 'example') {
       div.style.display = 'none';
    }
}
```

```html
<div class="test">
    ipsum
</div>
<div class="test">
    example
</div>
<div class="test">
    example complete
</div>
```