SolidJS

S

SolidJS

Solid is a declarative reactive Javascript library for creating user interfaces.

Join

useDeepCompareEffect in solid

How would I do something like this in solid-js (would I do this)? ``ts /** * Same as React.useEffect` but uses a deep comparison on the dependency array. This should only * be used when working with non-primitive dependencies....

Incoherent data with multiple createServerData$ in routeData

With the following route: ```ts export function routeData({ params }: RouteDataArgs) { const members = createServerData$( async (organisationId) => {...

Rendering issue

When trying to render the same JSX stored in state to the screen twice at the same time. It only renders one of the JSX elements. The JSX is passed as props to the component and is stored in an accessor function returned from the createReducer primitive. I am doing something wrong?...

Good way to create session cookie on every route?

```js const CreateUser: Component<{}> = (props) => { createServerData$(async (_, { request }) => createOrGetUser(request)); return null;...

How do i pass ref to child?

<div ref="how can i access this ref in ChildComponent?">
<ChildComponent/>
</div>
<div ref="how can i access this ref in ChildComponent?">
<ChildComponent/>
</div>
...

how to await createResource?

This feel like such a silly question, but how do I await createResource. I am having all sorts of type errors because I can seem to get the flow control working and am hitting undefineds all over the place.

Including solidjs router creates multiple instances of solid

I'm trying to add @solidjs/router to a project. But as soon as I import it and add the minimal setup, I get the following warning in my browser console:
You appear to have multiple instances of Solid. This can lead to unexpected behavior.
You appear to have multiple instances of Solid. This can lead to unexpected behavior.
...

Load data async

How can I trigger some data load asynchronously (with AbortController for cancelling) and show if not loaded some Loading-Component? I think I did something wrong with lazy... ```ts...

Importing web component `[...] does not exist on type 'JSX.IntrinsicElements'`

I'm trying to insert a web component in my Solid component: ```ts import '@power-elements/stripe-elements' ...

Is there a preference as when to use props or import data types?

With SolidJS you can export/import createSignal's getter and setter functions between files. How does this compare to passing the getter and setter as props? Thanks...

Is this possible to render a component as string in browser context ?

Hello, I saw in the discord that its impossible to use renderToString in the borwser. Is there another way to render to a string a SolidJS component ? Instead of using pure template string ?...

Solid Cache

hey @lxsmnsyc sorry to bother you. I´ve been trying your library, am I doing this correctly: ```typescript const [queryParams, setQueryParams] = useSearchParams() ...

Why useRouteData can return undefined?

In this example: ```ts export function routeData({ params }: RouteDataArgs) { return createServerData$( async ([_, id], { request }) => {...

useReducer equivalent?

Is there a useReducer equivalent? Thanks...

emmet support

Is there emmet support for SolidJS? Currently when I use it and want a class on my JSX element it will auto-complete with "className" instead of "class". Is there a setting I can change? Thanks...

Parent doesn't update view when state changes.

Problem: when the child component modifies the state of Auth, the rendering doesn't update. Auth component: ```js function Auth() {...

How to pass data from child component to parent?

We have props in solid for passing data down to child component. What about the opposite case when I need to pass some data back to the parent component? If I am not mistaken, in Vue.js there is a possibility to emit event from parent to child. How can I do it?

Unable to Render Skeleton Component

Hello ya'll, as the title says. I have a react project were i made a Skeleton component - works exactly as expected. However porting this component to SolidJS the Skeleton does not render anything unless i Here is my code:
Component...

solidjs not putting element in the correct spot.

https://derock.media/T45T7t.png https://derock.media/vTzp6m.png As you can see, for some reason, props.children is being placed outside of where it's supposed to be....

Solid's Ecosystem

Is there a list or something like that where I can find all most popular libraries to use with Solid? I mean libraries for i18n, forms, etc.