javascript - Re-rendering a single component, is all data needed? -
if have large app list of online users , 1 of users logs off, quite simple have react remove user giving list of current users. if list big, client have local cache , have server remove 1 user before rendering. simpe enough me deal with.
as far i've understood, recommended approach using react, wrap entire application within single component, , have lot of sub-components. @ least if you're using react entire ui. please correct me if i'm wrong.
now when users logs off, not need have local variable containing online users, have contain needed render rest of application isn't static, react diffing in shadow dom.
i'm pretty sure there's i'm missing. can me understand this?
Comments
Post a Comment