Michael P. Jung
Killing `pnpm dev` results in a defunct `esbuild` process
I've created a fresh solid start project with the default template. I noticed that pressing
Ctrl+C
causes a esbuild
process to linger around in the defunct
state.
So every time I start and stop the process another defunct esbuild process is created.
I guess this really is a vinxi
or vite
issue. I just wanted to ask here if anyone else ran into this issue and knows a fix.5 replies
Testing code without a render function
I was writing some utility functions using SolidJS primitives and ran into the issue that memos don't update. This is the minimal
vitest
where I could reproduce the issue:
Am I missing something?14 replies
Accessing parts of a Store (sub store, substore)
I ran into some typing issue with stores. I've got a component that expects a
data: T[]
and setter: SetStoreFunction<T[]>
. This is all fine when passing in a complete store as created by createStore(...)
but breaks down if I want to pass a part around:
e.g.
While this does indeed work at runtime TS goes bonkers about this as is doesn't know the type of args
and I can't deduce anything due to the overload of the SetStoreFunction
interface.
fwiw. would be a helper like subStoreSetter(store, "foo")
which returns that setter function so it could be used like that:
While we're at it that feature could also be a member of the setStore
function which would look really nice API wise:
I don't know if this is even possible or if I should be replacing that one store object with multiple arrays into multiple stores one per array.
Maybe that feature is still around somewhere and I'm just not seeing it. 🙈7 replies
ts-node not able to resolve ~ or node imports
I've got some scripts written in TypeScript in my project which I would like to execute. After some digging ts-node seams to be the obvious choice. However neither the
~
nor the import from node itself were working. After some digging I found that I can fix the node imports by either removing the types
key from the tsconfig compilerOptions altogether or adding node
to the array. Regarding the ~
paths however I'm stuck. I tried adding the tsconfig-paths
package which doesn't seam to work at all, tried adding imports
to the package.json
and switching to a #root
prefix instead.
Nothing seams to help and I'm stuck with the annoying error message:
5 replies