Тёмный
No video :(

Server Side Rendering with EJS and Node.JS 

Piyush Garg
Подписаться 162 тыс.
Просмотров 73 тыс.
50% 1

► Master NodeJS Playlist: • Master NodeJS
In this video, we take a deep dive into the world of server-side rendering with EJS and Node.js. We'll explore how to set up EJS as a templating engine, and how to use it to create dynamic views for your web application.
► Complete Full Stack Web Developer RoadMap 2023: • Complete Full Stack We...
Node.js is a JavaScript runtime built on Chrome's V8 JavaScript engine. It allows developers to run JavaScript on the server side, creating server-side applications with JavaScript.
► My Website: www.piyushgarg...
My Gears
► My Girlfriend: amzn.to/3WD6FRp
► Apple MacBook Laptop: amzn.to/3WBJgQn
► Anker USB Hub: amzn.to/3GhZSr0
► Blue Yeti Microphone: amzn.to/3YKZ9FT
► External 27” Monitor: amzn.to/3Vp3xaO
► Logitech MK295 Wireless Keyboard and Mouse: amzn.to/3DuL1bB
► Seagate Expansion 1TB External HDD: amzn.to/3QMm5Q8
► Tripod: amzn.to/3S4OwK4
► Ring Light: amzn.to/3YLf8DR
Disclaimer: All the links above are affiliate links.
Social Links
► Twitter - / piyushgarg_dev
► LinkedIn - / piyushgarg195
Video Titles
Creating Dynamic Templates with EJS in Node.js
EJS: The Easy Way to Build Dynamic Views in Node.js
Mastering EJS: A Step-by-Step Guide for Node.js Developers
Building Dynamic Websites with EJS and Node.js
Tags
#nodejs #javascript #expressjs #mongodb #mernstack #developer #api #https #server #javascriptinhindi #webdevelopment #webapp #realtimeapp #serverside #nonblockingio #tech

Опубликовано:

 

26 авг 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 97   
@shi-nee7966
@shi-nee7966 Год назад
another day of me feeling sorry for the kids like me who wanna learn backend but dont know about THIS GEM on youtube ooooofe
@mrlord8519
@mrlord8519 10 месяцев назад
Well we all are gems general engineering males 😂
@anshpradhan1954
@anshpradhan1954 3 месяца назад
you know what, what u just said is absolutely and prolifically true my friend, i was a noob in backend until i stumbled upon this playlist, Piyush is so good at explaining even the toughest concepts in node, which other you tubers just skip past.
@intensifyprakhar
@intensifyprakhar Год назад
By default VSCode does not have syntax highlighting for EJS template files. You need to install a plugin like this one - EJS language support. You also need to configure the file association for .ejs files. In order to do so type the following command (using CTRL + SHIFT + P) - Change language mode and then select Configure file association for .ejs, then select HTML from the dropdown.
@decodewithd2541
@decodewithd2541 4 месяца назад
Thanks for the help dear
@satyajitray4852
@satyajitray4852 4 месяца назад
thanks bro for the info
@harshitraj4667
@harshitraj4667 3 месяца назад
thnx bro for the help
@aditisharma3899
@aditisharma3899 8 дней назад
it was helpful :)
@mrcooleditz4740
@mrcooleditz4740 5 дней назад
thank you bro
@theknightblood3776
@theknightblood3776 Месяц назад
00:01 Server Side Rendering renders the entire web page from the server. 02:05 Templating engines in server side rendering solve the server side problem by reducing code complexity. 04:16 Using EJS as a templating engine for server-side rendering 06:34 Setting view engine and creating views folder for EJS files 08:27 Configuring Views Path for EJS in Express 10:26 Create an LI tag with the URL ID for server-side rendering with EJS and Node.JS. 12:34 Setting up a static router for serving front end pages. 14:42 Implementing form and handling post requests in Node.JS 17:22 Implementing server-side rendering and handling JSON response in Node.js with EJS. 19:41 Configuring ports and rendering pages 21:19 Creating a dynamic table in EJS 23:49 Server side rendering with EJS and Node.JS makes rendering and serving data to the front end easier
@nextleveltech267
@nextleveltech267 24 дня назад
Thank you so much...❤️❤️ You explained it so nicely and this is so informative...❤️❤️
@170_b_tarunakshabhattachar8
@170_b_tarunakshabhattachar8 6 месяцев назад
(FIXED)the shortIds are not showing when calling from ejs file. The html document is giving blank elements without shortId. : EDIT : Ok I was dumb to see a = in the syntax. I was doing without this =. This does not give any error thats why it took me time to notice.
@vimalsonara2819
@vimalsonara2819 4 месяца назад
Same bro 🤣
@abhishekchaudhary9033
@abhishekchaudhary9033 4 месяца назад
yeah bro ejs syntax is shit it took my whole day . Thanks
@pratyushpragyey7002
@pratyushpragyey7002 3 месяца назад
i'm so much thankfull to you for this one
@AbcdEfgh-pu6nq
@AbcdEfgh-pu6nq 7 дней назад
Ha ye "=" ne bhi mera time khaya
@User-yb3yc
@User-yb3yc Месяц назад
Great content Bhaiya. Pls also provide source code its hard to code and learn at same time
@pallabdandapat1866
@pallabdandapat1866 3 месяца назад
The best thing i love the overall explanation of the flow . 💘
@chiraglimbachiya2688
@chiraglimbachiya2688 23 дня назад
nice video. thanks
@Bankruptcoder786
@Bankruptcoder786 29 дней назад
bht braaa ustaad milaaa
@raza5500
@raza5500 11 месяцев назад
No default engine was specified and no extension was provided. ye error a raha h how to resolve??
@technologicalvivek7510
@technologicalvivek7510 6 месяцев назад
I have doubt.Frontend alag rakho backend se ,front-end ke liye ek hi project directory me folder banao or usme front-end ka code likh do using any framework like react js or angular js.Ye ejs karne ki kya jarurat
@tiwarikanishk5366
@tiwarikanishk5366 5 месяцев назад
server side rendering dynamic websites k liye boht fast hoti hai , frontend me api's ko data lana phir load krna ye sab boht time consuming hai
@RahulYadav-jk7um
@RahulYadav-jk7um Месяц назад
One of the best youtuber
@Vivek-rn9zb
@Vivek-rn9zb Год назад
Great tutorial keep it up bhaiya
@ShubhamPatil-rr4on
@ShubhamPatil-rr4on Год назад
Bhai you are doing amezing ♥️
@Gladiator_TV
@Gladiator_TV 5 месяцев назад
sir can we use JSX to do server side rendering?
@startercoder
@startercoder 5 месяцев назад
yes
@poojaganvir5631
@poojaganvir5631 7 месяцев назад
Great explanation, thank you so much
@pradeepKumar-rf9qb
@pradeepKumar-rf9qb Год назад
best tutorial with great explanation..
@timletotewes7017
@timletotewes7017 6 месяцев назад
Is there any (sensible) way of combining this with react & a modular structure?
@duztv5370
@duztv5370 5 месяцев назад
Hi! Have you been able to figure it out?
@Lauchmeister
@Lauchmeister 5 месяцев назад
You use React + React router for rendering & routing & for communication between React & Node you send fetch requests from react to the IP of your Node server. However, this won't be server side rendering anymore of course.@@duztv5370
@shubhamgupta-bl1tr
@shubhamgupta-bl1tr Год назад
What is difference between making a ui with template engine and with frontend library like react and next js ?
@Black-Curtains
@Black-Curtains Год назад
With ReactJs and NextJs, our web pages get loaded component-wise, without page reloading. I believe we reload webpages or urls in node.
@piyushgargdev
@piyushgargdev Год назад
I have already covered this in my REST API video in this playlist itself. Thanks ✨
@wrestling_world_007
@wrestling_world_007 Месяц назад
How to connect nodejs with Angular
@AbcdEfgh-pu6nq
@AbcdEfgh-pu6nq 7 дней назад
Ejs me seperate css or js file banti he kya or banti he to kese please batao
@RohitKumar-dy2gc
@RohitKumar-dy2gc 6 месяцев назад
amazing bro✨✨
@awangandas1700
@awangandas1700 8 месяцев назад
Action='/url' this part is creating the problem. Upon clicking on generate button nothing is happening. Plz help plz help
@rakeshgarlapati3965
@rakeshgarlapati3965 Месяц назад
same problem, have u found out the solution for it
@NCoder03
@NCoder03 6 месяцев назад
Ahhhh! I'm getting this error for 4 days 🤮 TypeError: Cannot read properties of null (reading 'redirectURL')
@agambajaj5600
@agambajaj5600 6 месяцев назад
i was also facing the same issue but the mistake was in updating visitHistory
@bineetjha2268
@bineetjha2268 5 месяцев назад
mee too same...@piyushgarg bhaiya please help
@maruthiagrawal4490
@maruthiagrawal4490 5 месяцев назад
If you are facing error then try to solve it by own and give time to think that what is the issue in it . Still, you are facing error then dont waste 4 days to just solve that error . So should use the chatgpt and give the command or just copy the error and paste in it. Your issue will be solved
@iamkashyapkumar
@iamkashyapkumar 5 месяцев назад
In index.js, change app.get("/:shortId",.......) to app.get("/url/:shortId", .........). This is happening because there two functions defined for / path, one is / and another one is /:shortId
@LG.KILLER
@LG.KILLER 5 месяцев назад
hello check your shortid(if any word capital or small) name in schema write same name in app.get when u fetch shortid
@chetanram797
@chetanram797 Год назад
Great video ❤
@khan_indiann
@khan_indiann 11 дней назад
If nodejs can return Ui then why we need reactjs?
@shashwatsingh2748
@shashwatsingh2748 7 месяцев назад
How do i pass objects from EJS File to back-end Route ?
@shreyanshkumarbasak7212
@shreyanshkumarbasak7212 5 месяцев назад
by renderinh home page in res.render in routes
@Genie7866
@Genie7866 5 месяцев назад
Why for home.ejs import is not necessary?
@shreyanshkumarbasak7212
@shreyanshkumarbasak7212 5 месяцев назад
because ur giving whole views file in path
@streetfoodworld8569
@streetfoodworld8569 10 месяцев назад
you are gem instructor
@healingfeels
@healingfeels 11 месяцев назад
sir source code error aa rha hai
@SulavGhimireeee
@SulavGhimireeee 8 месяцев назад
Thanks bro
@nooneknowsme1370
@nooneknowsme1370 9 месяцев назад
I have a question. When you are rendering the home page with shortid from the handleGenerateNewShortURL function, the path on the address bar is localhost:8001/url but i want it localhost:8001/ (the same url which is used to render home page). How do I do that? Just give me a basic idea please.
@akhileshsingh0136
@akhileshsingh0136 8 месяцев назад
bhai same dought mera bhi hai, ager aapka solve ho gya ho to kya code mil sakta hi🙏🙏
@ghost10326
@ghost10326 7 месяцев назад
@@akhileshsingh0136 Mila kya bhai ?
@tusharchawla1440
@tusharchawla1440 6 месяцев назад
​@@ghost10326Same doubt.Did you get the solution?
@agambajaj5600
@agambajaj5600 5 месяцев назад
Okay what you can do is you can update your form action = "/" and at static router add another route for a post request like you have done in this localhost:8001/url at the function in your controls there instead of only passing id as object pass url by URL.find({}) then it will work for you
@polymath-403
@polymath-403 Год назад
thanks man
@zafariqbal92
@zafariqbal92 Год назад
ZABARDAST!!!!
@codewithsam7300
@codewithsam7300 Год назад
what is the extension for ejs snippets?
@ZiaUlislam-do8iy
@ZiaUlislam-do8iy 4 месяца назад
Aslamullakum Sir I am new in node and start learning from your course and face the problem when I create Short id of given URL, it create only one url short id when I put another Url i will show E11000 key duplication how I can get rid this issues Sir
@rana.safikhan
@rana.safikhan 20 дней назад
unique true kiya hoga apne schema mein, aur kya same domain enter kr rhy thy?
@user-sq5si4vw6s
@user-sq5si4vw6s 10 месяцев назад
i have been following you for this playlist and i build same endpoints for post(making new url) and get(get all shorturl from database) that is '/' now i get an error whenever i use call for '/' in my browser then it shows a error which is in post request(as i tried to recall the same posted data in it using await) ans using console.log to print its timestamp just for fun, the error tells me that this timestamp is null and when i changed the url from '/' to '/url' for get and '/cal' for post the error was resolved as the browser only calls for get then why is this happening?
@ASD-mt4mf
@ASD-mt4mf 4 месяца назад
i faced the same issue. when my router was "/url" my ejs was not getting passed and i was getting the same error as yours: timestamp is nulll. So i also changed the route to something else and then it worked. did you find why it was happening? im confused
@heydude1551
@heydude1551 Месяц назад
Guys if someone had complete code for this particular lecture then pls kindly let me know .
@AkashKumar-z4k3f
@AkashKumar-z4k3f 18 дней назад
Bhai thora dheere dheere bataya karo bhai hum beggeners ko smjhne m thora time lagta hai
@zeta_meow_meow
@zeta_meow_meow Год назад
home.ejs mai urls.foreach mai urls not defined aara hai ...error giving , tried everything chatGPT , still not able to correct it
@lethalwarrior7
@lethalwarrior7 Год назад
for in loop use kar bhai
@hassanashraf2291
@hassanashraf2291 11 месяцев назад
@@lethalwarrior7 bhai for in loop kaise use kare isme for in ka syntax hi nhi hai
@AyushSingh-lp8wi
@AyushSingh-lp8wi 11 месяцев назад
Did you solved this error? I am stucked in it
@170_b_tarunakshabhattachar8
@170_b_tarunakshabhattachar8 6 месяцев назад
@@AyushSingh-lp8wi use this inside your "/test" route function. You should name the variable correctly before passing it to ejs file: return res.render("home", { urls: allUrls, });
@ShivendraPratap524
@ShivendraPratap524 Год назад
sir ye samajh nahi aya ki staticRouter kyu banaya , jab ki samework uske bina bhi ho sakta tha
@piyushgargdev
@piyushgargdev Год назад
Static Router is just for rendering pages, rest all handling POST, API requests.
@snehakumari935
@snehakumari935 Год назад
Can you provide source code link for this lecture I am getting an error.
@manasverma6610
@manasverma6610 Год назад
koi nai mai de doonga🤣🤣
@studyplans3783
@studyplans3783 2 месяца назад
ye wala sach me khatrank tha
@jashanpreet.753
@jashanpreet.753 3 месяца назад
10:30 recap
@anupkhismatrao9280
@anupkhismatrao9280 6 месяцев назад
@Akshay-be3xt
@Akshay-be3xt 4 месяца назад
anyone give source code
@gamerschoice779
@gamerschoice779 4 месяца назад
source code mila?
@akshaysaini001
@akshaysaini001 6 месяцев назад
source code send krdooo
@bunnytheweebster
@bunnytheweebster 7 месяцев назад
vid-22 ✅
@PrabalVerma-iy7yz
@PrabalVerma-iy7yz 5 месяцев назад
bro has given his girlfriend link in description💀💀
@TannuSuvarnakar
@TannuSuvarnakar 7 месяцев назад
Sir please source code de do
@kuchbhi-to2ru
@kuchbhi-to2ru 3 дня назад
bhai adhe video me se kaha pe gayab ho gaye he😂😂
@funnyfour3340
@funnyfour3340 Год назад
code dedo bhai
@BOSS-fc9lj
@BOSS-fc9lj 7 месяцев назад
yess plzz give the source code beacause my typed source code is giving error
@AhmadNasriya
@AhmadNasriya 6 месяцев назад
Don't write the title in English if you're not going to speak English 😒
@shreyanshkumarbasak7212
@shreyanshkumarbasak7212 5 месяцев назад
shut up
@TechnologyRelatedStuff
@TechnologyRelatedStuff Месяц назад
another day of me feeling sorry for the kids like me who wanna learn backend but dont know about THIS GEM on youtube ooooofe
Далее
Building Node.js Authentication from Scratch
39:09
Просмотров 145 тыс.
ПАВЕЛ ДУРОВ АРЕСТОВАН
1:45:21
Просмотров 114 тыс.
SPONGEBOB POWER-UPS IN BRAWL STARS!!!
08:35
Просмотров 18 млн
WTF Do These Even Mean
13:44
Просмотров 84 тыс.
Connecting NodeJS with MongoDB | Mongoose + Express
19:18
I Stopped Using Express.js: Because Bun and Hono 🔥
10:23
NGINX Tutorial - What is Nginx
14:32
Просмотров 119 тыс.
I forced EVERYONE to use Linux
22:59
Просмотров 461 тыс.
What is CSR SSR SSG and ISR
16:57
Просмотров 52 тыс.
The Story of Next.js
12:13
Просмотров 567 тыс.