Learn Express JS With TypeScript

  Рет қаралды 75,717

TomDoesTech

TomDoesTech

Күн бұрын

Пікірлер: 87
@JoJoAcrylicArtwork
@JoJoAcrylicArtwork 10 ай бұрын
finally a tutorial that doesn't leave you hanging on getting the fuller pic for proper type safety and production level usage. Thanks Tom
@basiccoder2166
@basiccoder2166 Жыл бұрын
Watch entire video without getting bored or distracted. Beautifully explained
@Skylla54
@Skylla54 3 жыл бұрын
I did a 40 hours node js course. These tutorial are just amazing to keep all the concepts and techniques fresh for my next Hackathon. 🤤 And perfect 4 dinnertime :)) 🍖
@GeorgiosAmsterdam
@GeorgiosAmsterdam 5 ай бұрын
Looks like I finally found the video that I need, and for the first time I see an instructor using YARN..... never a break.
@MrKeepItTrill
@MrKeepItTrill 2 жыл бұрын
Came with the intention of skimming this just to see what I need to do to get Express working with TS (turns out not much). Left with one of the best and clearest introductions / refreshers on Express in general that I've ever seen.
@TomDoesTech
@TomDoesTech 2 жыл бұрын
So glad you liked it :)
@mizouhamza3244
@mizouhamza3244 2 жыл бұрын
I recommend to any new comer to Nodejs with Express. This video is what you need to start and get on your feet, personally I definitely enjoyed it.
@angrysmilex
@angrysmilex 2 жыл бұрын
28:25 - Request & response generics - YOY!! I finally find this useful and simple solution
@gosnooky
@gosnooky Жыл бұрын
NestJS is the goat. Not to confuse with NextJS, the React framework. Some people hate on it because it's TS first and feels a lot like Java/Spring or Angular, but those are both good things in my book because on the emphasis on type-safety and modularity.
@TomDoesTech
@TomDoesTech Жыл бұрын
Yeah, not a fan of NestJS
@7MaticCode
@7MaticCode 10 ай бұрын
This is the best tutorial for express with typescript. Thank you for this tutorial I learned a lot
@Creamworks
@Creamworks 3 жыл бұрын
Fantastic video! I'd also love to see a deep dive tutorial on Express + Mongoose with TS (file structure, strict typing etc.).
@jereramirez7433
@jereramirez7433 2 жыл бұрын
Tom, this is so helpful! Im coming from Java-Spring stack and this is helping me so much to understand what I need to do to work as I used to. THANK YOU!
@stijnschuurman9347
@stijnschuurman9347 3 жыл бұрын
Thanks Tom! I was confused with the `app.use(express.json())` because for some reason it did not function as it should for certain versions. Explained the middleware part really good. Thanks a lot :)
@chiragsharma4799
@chiragsharma4799 2 жыл бұрын
github.com/chiragmehta900/node-typescript-boilerplate-postgres Hey guys, try out this node js typescript boilerplate Please stare at this repository if you like this.
@nextdev3637
@nextdev3637 2 жыл бұрын
Wow, I was searching for it since 1 hour.
@josephjoey3904
@josephjoey3904 3 жыл бұрын
Great work Tom. I have gotten the hang of TS with React but not much on the back end side
@vilijanac
@vilijanac 3 жыл бұрын
It is itself an fake back end side. Client needs at the front end needs to present. Receives only string of text. Most web browsers will reject as an web page.
@josephjoey3904
@josephjoey3904 3 жыл бұрын
@@vilijanac wtf u talking about?
@postgres2269
@postgres2269 Жыл бұрын
Thanks a lot for sharing this great knowledge for free. I never thought I would learn many new things from you.
@oz4549
@oz4549 2 жыл бұрын
underrated channel
@arberi99
@arberi99 3 жыл бұрын
Thank you for this amazing video!
@adventurer2395
@adventurer2395 2 жыл бұрын
You’re a good teacher, and this complements your other API video that had a faster pace. Since you’re using TS, it would be awesome to see an object-oriented API.
@TomDoesTech
@TomDoesTech 2 жыл бұрын
Thank you :) Yeah I will think about an OOP approach, I do prefer more functional programming though.
@jessejulian9069
@jessejulian9069 Жыл бұрын
@@TomDoesTech Whats the difference between the two if i may ask? Is it simply receiving and returning JSON?
@TomDoesTech
@TomDoesTech Жыл бұрын
@@jessejulian9069 There's a lot different, It will just confuse you if I try explain it in a comment. There should be lots of videos on YT explaining it
@martinlupa8692
@martinlupa8692 Жыл бұрын
Great video! Thank you!
@k12i
@k12i 2 жыл бұрын
Thank you Tom for the amazing explanations! I have learnt heaps just from this tutorial :)
@TomDoesTech
@TomDoesTech 2 жыл бұрын
Great to hear!
@taosade
@taosade 3 ай бұрын
what's the extension for such a cool terminal in vscode?
@tadeuszjiwu255
@tadeuszjiwu255 2 жыл бұрын
Thank You Tom, great tutorial!
@mossaabkanzit9403
@mossaabkanzit9403 2 жыл бұрын
That was really instructional! Maybe in a future video you can cover clean / hexagonal architecture with express and typescript. Thanks for the video and looking forward to more videos.
@TomDoesTech
@TomDoesTech 2 жыл бұрын
Thanks for the suggestion. I will look into hexagonal architecture and see if it's something I'd make a video out of
@jamesperalta35
@jamesperalta35 Жыл бұрын
great work!
@true_visual
@true_visual 9 ай бұрын
I am close to complete my Angular course at the moment. I will soon need to learn Express to come closer to MEAN and I am so excited. Can someone learn Express in 40 minutes though? It seems short unless it's really that quick to learn Express! Thank you very much for this!
@TCErnesto
@TCErnesto 2 жыл бұрын
11:36 is it needed to type the parameters? TypeScript is pretty good at inferring types. In this case, thanks to the signature of `get`, VSC and we know the types of `req` and `res`
@2gbeh
@2gbeh 7 ай бұрын
Let's go 👍
@codforc
@codforc Жыл бұрын
thank you!
@pheonixking1234
@pheonixking1234 2 жыл бұрын
Very good tutorial!
@marianofarace308
@marianofarace308 2 жыл бұрын
Hi Tom, I'm getting an error on every empty bracket here "req: Request", Don't use `{}` as a type. `{}` actually means "any non-nullish value". How do you deal with that?
@Kamilek96
@Kamilek96 2 жыл бұрын
Great tutorial. Could you advise me, which of your tutorial should I take next, if i interested in backend stuff? Many thanks =)
@TomDoesTech
@TomDoesTech 2 жыл бұрын
You could try building the auth API kzbin.info/www/bejne/p6rPeJShnpV9nrs
@k12i
@k12i 2 жыл бұрын
Hey Tom, what did you use for formatting the code with auto save? Is it prettier?
@TomDoesTech
@TomDoesTech 2 жыл бұрын
Yeah prettier
@rathan235
@rathan235 2 жыл бұрын
well explained!
@jessejulian9069
@jessejulian9069 Жыл бұрын
Hey Tom, what script would we use to run the server in production?? I'm referring to the scripts we add within the package.json file in order to run our server. I've watched a few of your videos on Express with TypeScript but I've only seen you set a script for Development
@TomDoesTech
@TomDoesTech Жыл бұрын
What script?
@MassGueye-sr4kj
@MassGueye-sr4kj Жыл бұрын
what was that technic names with middleware
@devloperadda1350
@devloperadda1350 3 жыл бұрын
Thanks
@mybuddy11
@mybuddy11 Жыл бұрын
could you please a lecture on micro service with express -typescript?
@logarithm0
@logarithm0 2 жыл бұрын
Top
@savithadatchu1534
@savithadatchu1534 2 жыл бұрын
Hey Tom, What is the use of express interfaces, when even without them the inbuilt functions of req and res are accessible directly.
@TomDoesTech
@TomDoesTech 2 жыл бұрын
If you pass req and res to a controller for example, in the controller the interfaces are not accessible, so explicit types are helpful
@valentinussofa4135
@valentinussofa4135 2 жыл бұрын
Thanks for this tutorial. I want to ask, Why you don't use nodemon package?
@TomDoesTech
@TomDoesTech 2 жыл бұрын
don't need it
@editingtuto1.011
@editingtuto1.011 Жыл бұрын
I Want to learn session management with typescript.
@filipedonatti8872
@filipedonatti8872 2 жыл бұрын
could explain what is .locals at 28:50 ?Maybe explain a little further about its usability if you don't mind
@TomDoesTech
@TomDoesTech 2 жыл бұрын
The res.locals object has properties that are local variables within the response, and will be available in templates rendered with res.render
@howuseehim
@howuseehim Жыл бұрын
How do you build for production? 😢
@talhakhadim111
@talhakhadim111 Жыл бұрын
which tool are you using for auto complete in cli?
@TomDoesTech
@TomDoesTech Жыл бұрын
I think it's zsh-autocomplete
@coderboysobuj
@coderboysobuj Жыл бұрын
How to i deploy express typescript project on cpanel?
@yoman9446
@yoman9446 3 жыл бұрын
Thanks a lot! Can you do a tutorial on using NextJS with custom express backend with typescript?
@HologramJay
@HologramJay 2 жыл бұрын
Thanks for the tutorial, Tom. It was really helpful. I just had a quick question. When typing the Request object, how would we access ResBody? I'm trying to set its type to a string, but I can't seem to figure out how to log it out like I can with req.params, req.body, and req.query.
@indigosay
@indigosay 3 жыл бұрын
You should teach us to extend Request witn additional properties, bro
@Randomuser21265
@Randomuser21265 3 жыл бұрын
Where is the github link?
@TomDoesTech
@TomDoesTech 3 жыл бұрын
I haven't added it to GitHub because there was no real working code. I can make a repo with all the examples if that would help
@Euquila
@Euquila 2 жыл бұрын
Personally, I use Typescript very minimally. Like, I would never type Request, Response, and NextFunction... that would annoy me as all hell. I might type out the shape of an object or props or something though
@TomDoesTech
@TomDoesTech 2 жыл бұрын
That's the beauty of TypeScript, it's more opt-in. I usually don't add types for everything, especially if TS knows the type implicitly. However, I add more types in these videos because I want to stress how to find the types that can be used by going into the module and seeing what's exported.
@IkraamDev
@IkraamDev 3 жыл бұрын
My boss told me Golang is a better tool than NodeJS. It would be interesting if you learnt Go and made a video like this in Go.
@TomDoesTech
@TomDoesTech 3 жыл бұрын
For what specifically is Go better than Node.js? yeah, I've wanted to learn Go for ages but have only dabbled in it a little bit.
@kalush81
@kalush81 2 жыл бұрын
There is almost no typescript involved in this video.
@TomDoesTech
@TomDoesTech 2 жыл бұрын
I don't think stuffing types in where they don't improve the DX is an appropriate use of TS, therefore there is enough TS in this video. If you disagree, that's fine but welcome to tech where nobody agrees on anything.
@kirarevcrow
@kirarevcrow 3 жыл бұрын
You barely talked about the error handling.
@TomDoesTech
@TomDoesTech 3 жыл бұрын
I talked about it enough in terms of Express, since it's just normal Node error handling.
@tejasjani2544
@tejasjani2544 Жыл бұрын
Js realised it's mistake and want be a java
@TomDoesTech
@TomDoesTech Жыл бұрын
lol what?
@mjerez6029
@mjerez6029 Жыл бұрын
Is 2023 last thing you should do is express, there are waay better alternatives. Express is just awful
@TomDoesTech
@TomDoesTech Жыл бұрын
What if you are interviewing for your dream job and they have a large Express app and expect you to know how to use it? Probably pretty import to learn it.
@TomDoesTech
@TomDoesTech Жыл бұрын
Otherwise I'd agree, I always start new projects with Fastify
@aayushdhakal4142
@aayushdhakal4142 2 жыл бұрын
No explanation at all. Just keeps on writing code, very disappointing.
@TomDoesTech
@TomDoesTech 2 жыл бұрын
Sorry, I'll give your money back
@aayushdhakal4142
@aayushdhakal4142 2 жыл бұрын
@@TomDoesTech give my time back
@TomDoesTech
@TomDoesTech 2 жыл бұрын
@@aayushdhakal4142 I didn't strap you down and make you watch it
@aayushdhakal4142
@aayushdhakal4142 2 жыл бұрын
@@TomDoesTech you put it on youtube to watch
@TomDoesTech
@TomDoesTech 2 жыл бұрын
@@aayushdhakal4142 Exactly, no restraints involved
Learn Next.js With TypeScript in 30 Minutes
33:12
TomDoesTech
Рет қаралды 91 М.
Which team will win? Team Joy or Team Gumball?! 🤔
00:29
BigSchool
Рет қаралды 15 МЛН
СОБАКА ВЕРНУЛА ТАБАЛАПКИ😱#shorts
00:25
INNA SERG
Рет қаралды 3,6 МЛН
Express JS Crash Course
1:14:01
Traversy Media
Рет қаралды 968 М.
Build a CRUD API with TypeScript, Express, MongoDB, Zod and Jest
1:38:56
RESTful API using Node JS, MongoDB & Typescript IN-DEPTH [2022]
49:06
The Nerdy Canuck
Рет қаралды 56 М.
NestJs Course for Beginners - Create a REST API
3:42:09
freeCodeCamp.org
Рет қаралды 1,5 МЛН
Build a REST API with Node JS and Express | CRUD API Tutorial
1:01:16
JavaScript Mastery
Рет қаралды 545 М.
Which team will win? Team Joy or Team Gumball?! 🤔
00:29
BigSchool
Рет қаралды 15 МЛН