user's flow of thought to stay uninterrupted, even though the user will notice the delay. Normally, no special feedback is necessary during delays of more than 0.1 but less than 1.0 second, but the user does lose the feeling of operating directly on the data. —Jakob Nielsen
the user's attention focused on the dialogue. For longer delays, users will want to perform other tasks while waiting for the computer to finish, so they should be given feedback indicating when the computer expects to be done. Feedback during the delay is especially important if the response time is likely to be highly variable, since users will then not know what to expect. —Jakob Nielsen
might care about time to first headline. • Twitter might care about time to first tweet. • Chrome might care about time to inspect element. • What does your product or project care about?
the box. • Being all crazy about performance at the expense of creating value for your users is not awesome. • We’re going to look at some contrived examples because most larger code bases are: private, hard to grok during at talk, and hard to fake.
reconcile the virtual DOM if you don’t have do. • Keep your state flat and primitive. • Don’t add functions to the call stack if you don’t need to. • Share things that don’t change instead of reinventing the wheel.
real DOM is slow. • Making lots of little changes to the DOM can add up. • The virtual DOM let’s us change an object in memory—which is way faster. • Then it figures out of to do the most efficient change all at once.
News About React Hooks', description: 'They exist, but not yet.', }, second: { title: 'Classes Are Dead! Long Live Classes!', description: "Or, maybe not. I don't really know.", }, }; posts.second = { ...posts.second, description: 'Definitely not soon.' };
News About React Hooks', description: 'They exist, but not yet.', comments: { 123: { author: 'Steve Kinney', bio: { twitter: '@stevekinney', company: 'SendGrid', }, body: 'First!', responses: { 456: { author: 'Ksenia Coulter', body: 'You never sent me your fun fact!', // What if I want to update this? } }, }, }, }, // … };
data, allowing Redux to store the minimal possible state. • Selectors are efficient. A selector is not recomputed unless one of its arguments changes. • Selectors are composable. They can be used as input to other selectors. • (This list is from the official documentation.)
performance on fancy MacBook Pros or consumer-grade hardware? • Are we simulating less-than-perfect network conditions. • What is our performance budget?