andrewdavey / andrewdavey/immutable-devtools

Typo in renderIterableBody?

Aberta
#36 0 comentários 0 reações 0 responsáveis Ver no GitHub
Linguagem predominante
JavaScript
Estrelas
671
Forks
32
Métricas de merge de PRs
Nenhum PR com merge em 30d

Descrição

Hi, I was reading through the code of this library, and read the `renderIterableBody` function. Here is the source for it:

```javascript
const renderIterableBody = (collection, mapper, options = {}) => {
if (options.sorted) {
collection = collection.sortBy((value, key) => key);
}
const children = collection
.map(mapper)
.toList();

const jsList = []
// Can't just call toJS because that will also call toJS on children inside the list
children.forEach(child => jsList.push(child))

return [ 'ol', listStyle, ...children ];
}
```

It seems that the author carefully crafted the `jsList` list, but then forgot to use it, and mistakenly used `children` instead.

Guia de contribuição

Nenhum guia de contribuição indexado para este repositório

Avaliação

Esta issue ainda não foi avaliada.

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.