antonio-ramadas/palbum

Refactor App.js

Offen

#7 geöffnet am 12.03.2019

 (0 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)JavaScript (0 Forks)auto 404
frontendgood first issue

Repository-Metriken

Stars
 (9 Sterne)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

App.js is doing more than it should. It populates the page (search bar and table).

However, whenever there is an update to the list (e.g., a new album is added) the whole component is rendered. As you can guess, there is no need for it.

Also, with a refactor, the logic would no longer be on a single file and its size will most likely be reduced.

I suggest having one component for the search bar, another for the table and App.js simply calls them on the rendermethod.

Contributor Guide