felds
u/felds
This is how I'm create my context and provider:
export const DummyContext = createContext<{ run: () => void }>({
run: () => console.log("Running from INITIAL"),
})
export function DummyProvider({ children }: { children: JSX.Element }) {
const run = () => console.log("Running from PROVIDER")
return (
<DummyContext.Provider value={{ run }}>
{children}
</DummyContext.Provider>
)
}
I'm then adding this provider to the top of my rendering tree:
render(
() => (
<DummyProvider>
<App />
</DummyProvider>
),
root!,
)
Inside the <App> component, I'm calling run like so:
const App: Co
TLDR: Implementing color scheme switchers repeatedly feels inefficient. Expanding this functionality at the browser level would streamline the user experience, eliminate redundant JavaScript and styling, and provide a consistent, centralized interface for users to control their preferences across websites. It would also reduce clutter on sites, as switchers could be built into the browser UI.
I'm so tired of implementing color scheme switchers over and over again. The implementations are always overly complicated for what they do, and I always end up thinking that this could and should be much easier to achieve with browser-level support.
Here's my (non-exhaustive) list of reaso
If you had to recommend one album to someone that had never listened to math rock, what would it be?
Although I’m always interested in new music, what I’m looking for now are the timeless classics that define the genre in your opinion.
So what is the quintessential math rock album to you?
I know this a stupid question, but what is Uncle Bens Ready Rice? We don't have it in my country and I'm not sure what product would be equivalent to it around here.
Is it pre-boiled, parboiled, or just dry grain? Is there anything else inside the pouch?
And if I don't find anything like it around me, how can I substitute it?
(I have some experience growing monotub, if it helps)
Don't get me wrong: I love how intelligent the Jetbrains products can be about a codebase, how it points out potential flaws in the code early and how powerful the autocomplete is.
But it has it's drawbacks, too. They tend to have a very poor text editing experience^([1]) and, worst of all, they are paid. While I think it's worth the money, it makes it harder to get people on board with a language/framework that effectively requires a special editor to be ergonomic. Having the Symfony plugin being freemium doesn't help either.
Hell, I use Symfony for a few years and I don't know the namespaces of basic components from the top of my head.
I f







