Problems with ~ then " Cannot read properties of null (reading 'useEffect')"

Hello, I’m struggling with the install. I search on many posts but didn’t find any similar reported.
I watched and re-did the install at least 8 times…
Still same issues…

First :
I did exactly what is mentionned in the video. git, node, pnpm, …
but when launching the “pnpm run dev” I get errors with the alias ~ which doens’t seem to be recognized.
I keep having this kind of error “Cannot find module ‘~/utils/constants’ imported from ‘C:/Users/user/Documents/bolt.diy/app/lib/.server/llm/create-summary.ts’”. I could replace all the ~ by the real path (…/… or so ) - could also define the path definition in vite.config.ts with

resolve: {
  alias: {
    '~': path.resolve(__dirname, 'app')
  },
  dedupe: ['react', 'react-dom']
}

Second :
Having added this in vite.config.ts, the “~” issue seems solved but the I have the error
“Unexpected Server Error
TypeError: Cannot read properties of null (reading ‘useEffect’)”

The console does only show “Server Error 500”

I restarted the installation process many times. Checking node and pnpm version…
node : v22.13.1
npm : 11.0.0
pnpm : 9.4.0
and Windows 10 - 22H2

Anyone experienced the same ?

Thanks for any helpful tip !

1 Like

same problem here in a Window 10 pc

Hi @blaise6640,
which video you refering to? Mine or another?

Second question => Are you on the stable or main branch? If on stable, try use main quickly and see if it is working then.
You should not need to change any source code files to run bolt.

@codikaorg you also watched my video and followed the instructions as provided in the tasklist?

Yes my friend, i am updating node, npm, installing C# distributable to eliminate any error, i am also in stable branch

@codikaorg thanks for the infos. Did you also try, as suggestet in the comment for @blaise6640, to use the main branch and see if it fixes it?

Also can you tell me if a requisite to use Chrome Canary? or i can use the standard chrome

Yes you can just use chrome. Canary is not needed anymore. We need to remove that from the docs.

1 Like

Well, I tried the main also but still have the same issue…

I removed then reinstalled C++ but still same issue…

Ok, just to make sure, you startet then with a clean project again and reinstalled the dependencies with PNPM (not npm, cause if you did one time wrong and then just do PNPM after again, its not working).

git clone -b stable https://github.com/stackblitz-labs/bolt.diy.git
cd bolt.diy
pnpm install
pnpm run dev

this would be the steps in short.

This is what I did about 20 times (sure I did pnpm) but unfortunately always the same.
Would there be some other environment variables to set up ?

@private.winters.bf3 maybe you have any idea? I am out of ideas :smiley:
Just saw you both are from Brussels :smiley: