Hi, for some reason some of the node typescript de...
# support-questions-legacy
b
Hi, for some reason some of the node typescript definitions doesn't work for me. Here is a small repro showing how I experience the middleware and errorHandler properties not being linked properly https://stackblitz.com/edit/typescript-qopxcd?file=index.ts
r
hey! the import statements for the middleware and error handlers are wrong
if you see the guides we have -> backend setup -> then you will find the right imports for them based on the node framework you use
b
I don't see a "backend setup" in the list of User Guides
r
click on one of the guides
in there you will see a start here section on the left
and then follow along
b
Oh, it's completely different from the express guide I found previously https://supertokens.com/docs/nodejs/2.0.x/usage-with-express/setup
Thanks!
r
yup. The express guide you linked to above is of a very, very, very old version
b
I have this express app, but I don't have separate apiDomain and websiteDomain as it's all server rendered. It's basically all running on the same port. Is that not compatible with SuperToken?
r
that is. Just set the same value for apiDomain and websiteDomain, but change the websiteBasePath or the apiBasePath
b
awesome! I added the cors() and middleware() to express, and successfully get the /auth/dashboard route, but the auth/signup doesn't exist
r
which recipe have you initialised?
b
Session and EmailPassword
and Dashboard
r
can you enable backend debug log and then show me the output?
b
r
are you sending a POST request?
b
I opened the launched the server and went to auth/signup where it would make a get request to that route
r
right yea. so there is no GET API for that
try sending a POST request
b
aaah, that way, so I make the ui and fire a post request to that route
r
yes
thats if you are making your own UI
you can also use our pre built UI
if you follow the pre built UI section
b
I'm stuck with .ejs view for now, so I don't think i can use those unfortunately
r
ok
2 Views