lobster theremin
lobster theremin
SSolidJS
Created by lobster theremin on 10/9/2024 in #support
Solid Router 0.14 Suspense Behaviour
thanks! must have missed that
4 replies
SSolidJS
Created by Grahf on 2/22/2024 in #support
stop screen flicker from createResource refetch?
11 replies
SSolidJS
Created by Grahf on 2/22/2024 in #support
stop screen flicker from createResource refetch?
11 replies
SSolidJS
Created by bigblind on 2/10/2024 in #support
Best practices for reactively updating a store
function createDeepSignal<T>(value: T): Signal<T> {
const [store, setStore] = createStore({
value,
});
return [
() => store.value,
(v: T) => {
const unwrapped = unwrap(store.value);
typeof v === "function" && (v = v(unwrapped));
setStore("value", reconcile(v));
return store.value;
},
] as Signal<T>;
}
const [resource] = createResource(fetcher, {
storage: createDeepSignal,
});
function createDeepSignal<T>(value: T): Signal<T> {
const [store, setStore] = createStore({
value,
});
return [
() => store.value,
(v: T) => {
const unwrapped = unwrap(store.value);
typeof v === "function" && (v = v(unwrapped));
setStore("value", reconcile(v));
return store.value;
},
] as Signal<T>;
}
const [resource] = createResource(fetcher, {
storage: createDeepSignal,
});
https://docs.solidjs.com/references/api-reference/basic-reactivity/createResource#v150 you can use storage to return a store from a resource fetch
6 replies
SSolidJS
Created by Yaki (ShibaTales) on 2/9/2024 in #support
Uncaught ReferenceError: React is not defined
I'm not sure if that adapter is needed or up-to-date 3 months since last update
43 replies
SSolidJS
Created by Yaki (ShibaTales) on 2/9/2024 in #support
Uncaught ReferenceError: React is not defined
well... it probably doesn't fwiw it might be flowbite you'd have to check by commenting out imports if removing flowbite fixes it... well, then it's flowbite
43 replies
SSolidJS
Created by Yaki (ShibaTales) on 2/9/2024 in #support
Uncaught ReferenceError: React is not defined
Do you use any packages?
43 replies
SSolidJS
Created by Osman on 10/25/2023 in #support
createStore not reactive
Can you provide a reproduction in the Solid playground?
3 replies