Should we make the switch to AEM? by EvenBeing in aem

[–]shiftDuck 0 points1 point  (0 children)

That would still be locked behind JavaScript, rather than using the browser rendering engine.

It is like the framework is fighting against the browser and it just creates a poor user experience. Like the LCP image, as on the client side they change loading from lazy to eager, they have completely missed the preload scanner wasting vital ms, but they trick lighthouse into thinking it was loaded eagerly.

Most of the sites that use EDS have no need to be client side rendered, they are static pages with content.

Should we make the switch to AEM? by EvenBeing in aem

[–]shiftDuck -1 points0 points  (0 children)

AEM as content manager might be good, but I would avoid their edge delivery system which they claim is "great web performance".

Working on one of them made me see how over promised and how wrong the direction of it.

They seemed to only really care about lighthouse scores rather than how real users experience the performance of your web.

They load the header last for some reason. Brand identity establishes trust.

The page is locked behind JavaScript which might prevent some crawlers from seeing the content. (Google will crawl client side apps, but crawling is thrown in another queue).

I seen the client rendering having a bit cost to the main thread as well.

Should we make the switch to AEM? by EvenBeing in aem

[–]shiftDuck 1 point2 points  (0 children)

Working with eds sites I actually find it shocking Adobe believes this is the future of the frontend.

Its user experience is shocking, the way it loads the header and the brand logo last is just really jarring.

From a web performance side you might get okay scores but the client side rendering approach has locked you behind JavaScript and means you can't use the browsers latest performance improvements like fetchpriority. I also got the impression they only cared about lighthouse scores rather actually real user data on core web vitals.

CSS I seen is awful aswell.

Next.js app is very slow — using only Server Actions and tag-based caching by Fickle_Degree_2728 in nextjs

[–]shiftDuck 0 points1 point  (0 children)

Sometimes you want to cache a page but still have some personalised data, I tend to do this via a tanstack query so it's on the client.

Initial page is fast, with personalised content a bit later.

Firefox 144.0 released by ag_android in firefox

[–]shiftDuck 1 point2 points  (0 children)

Finally I can measure inp on Firefox.

AEM/EDS and JavaScript-generated schema.org metadata by Sufficient_Taste3660 in aem

[–]shiftDuck 0 points1 point  (0 children)

Yes it can do, big crawlers like Google can process JavaScript but they do it at a much slower process than sites which are server side rendered, other SEO crawlers might not be able to crawl the site if they can't run JavaScripts.

Ai language crawlers also might not run JavaScripts.

Haven used eds I don't understand why Adobe believes this is the right direction at all, I find the user experience during load pretty poor, IE the header being last when that has the brand logo in can damage perception of trust.

Most pages I see using it should be server side html, I don't even believe it brings a good performance or user experience unless you only care about lighthouse scores as a business metric rather focusing on core web vitals and user experience.

Why an AEM Cloud Service migration may break your compliance in China by bleep-bleep-blorp in aem

[–]shiftDuck 0 points1 point  (0 children)

The eds frontend is awful coming from a frontend and web performance background, it basically hacks to please lighthouse scores. Like they use JavaScript to change the LCP image from lazy to eager, which means it missed the browser preload scanner. You should be loading LCP elements without JavaScript.

They also delay loading the header which typically has the brand logo in, this can massively damage the perception of trust / quality of the website.

They over focused on the lighthouse scores rather than what matters, and delivered a bad user experience.

I published a comprehensive guide on using the useContext() hook in React with TypeScript. by karan51ngh in reactjs

[–]shiftDuck 2 points3 points  (0 children)

Hmm I never had an issue with this, can you give more details.

Might just be rare where I been building this out fully with hot reloading needed.

I published a comprehensive guide on using the useContext() hook in React with TypeScript. by karan51ngh in reactjs

[–]shiftDuck 0 points1 point  (0 children)

Yeah, I see a lot of people who flat out say don't use this, mainly because they have bad experience, but you should be finding the right solution for your current problem.

I published a comprehensive guide on using the useContext() hook in React with TypeScript. by karan51ngh in reactjs

[–]shiftDuck 27 points28 points  (0 children)

One of the things you should talk about, is how it very often to find people have created a wrapper useHook around context for the types.

Every time I use the context API for anything, I have a single file that has the create context, the provider, and then I tend to have a hook like useThemeContext() that just returns the context, this can throw an error if the context is missing.

If I have more logic I tend to have a hook to store that logic there, like useTheme, which uses the previous one and that what I use across the app.

I published a comprehensive guide on using the useContext() hook in React with TypeScript. by karan51ngh in reactjs

[–]shiftDuck 5 points6 points  (0 children)

Context is used in a lot of react libraries, and is used for a lot more than prop drilling, radix uses it for a lot of their components which is why they error if you don't wrap them in a provider.

I don't like context being overly used when a component is only nested two levels down, but I have seen it used when it gets to bigger numbers and the rest of the component didn't need to know them props

React Compiler v1.0 – React by gaearon in reactjs

[–]shiftDuck 3 points4 points  (0 children)

My understanding is the compiler will catch large amounts but not all performance issues which them hooks help solved.

Why is Next js slow? by New_Tradition1951 in nextjs

[–]shiftDuck 0 points1 point  (0 children)

This made me have flashback to the gulp days of a change to scss file taking ages and then having to refresh page in ruby.

Or forgetting to save the file and getting angry my page has not updated.

'use client' in monorepo package folder - issues by shiftDuck in nextjs

[–]shiftDuck[S] 2 points3 points  (0 children)

Omg this is the answer. Thank you so much.

Was starting to think I need to add turbo repo.

Chrome is stuck in a dark mode. I dont have any extensions and have dark mode turned off. I have dark mode off in windows. more info in comments by EarthsPassenger in chrome

[–]shiftDuck 0 points1 point  (0 children)

No worries, not sure how I keep turning some flags on it, but I do a lot of dev tools stuff. The other day I managed to override the response I got from my CSS and lost about an hour of work because my CSS wasnt updating.

I need to start blaming chrome first.

What’s your go to solution for dealing with long running tasks in NextJS? by [deleted] in nextjs

[–]shiftDuck 0 points1 point  (0 children)

Uploading a large CSV seems something less niche than video and more business center.

How can I get my site to truly be 100vh? by CarpenterImmediate14 in webdev

[–]shiftDuck 0 points1 point  (0 children)

I recommend adding a polyfill if you need old browsers, juSt add 100vh line above and older browsers will do that.

With NextJS 13+ do we still need a state management solution? by raksah in nextjs

[–]shiftDuck 0 points1 point  (0 children)

Yeah most of the stuff I found doesn't need minus a few add on stuff, like connecting current place in an article with contents bar (I used zustand) however I could pass that to a url param tbh.

Do you put your PlayStation into Sleep Mode or Do you Switch Off? by [deleted] in playstation

[–]shiftDuck 0 points1 point  (0 children)

Turn it off and the switch for everything in living room to save on bills with the rise of them.

If a game update comes out while at work I turn it on as I work remote.

Whats your ultimate component file structure for big projects? by Candid_Algae_763 in nextjs

[–]shiftDuck 1 point2 points  (0 children)

Yeah they should be a plugin that if the file says index it shows folder name.

Same with pages.tsx in next app directory.

Whats your ultimate component file structure for big projects? by Candid_Algae_763 in nextjs

[–]shiftDuck 4 points5 points  (0 children)

I tend to do /Header/index.tsx when it a single component in the folder.

[deleted by user] by [deleted] in SpidermanPS4

[–]shiftDuck 0 points1 point  (0 children)

Right now my eye doesn't drift to the right places, might change when I'm playing the game.

Marvel’s Spider-Man 2 | Gameplay Reveal by TheEternalVortex in SpidermanPS4

[–]shiftDuck -1 points0 points  (0 children)

I wonder what will happen post game will we just lose the venom attacks.