Next.js 14 E-Commerce Website (Server Actions, TypeScript, Deployment, TailwindCSS, Prisma, DaisyUI)

Поделиться
HTML-код
  • Опубликовано: 4 янв 2025

Комментарии •

  • @MCStarYT
    @MCStarYT Год назад +5

    Yes, a stripe tutorial will be 🔥🔥🔥

  • @ban_droid
    @ban_droid Год назад +7

    i really love daisyui, it is very underated tailwind library, different from other that use client function. it does not need extra setup to work in both server-component or client-component, theming customization is amazing, great color combination, easy to override the style ❤

    • @codinginflow
      @codinginflow  Год назад +1

      I agree with all of these points 👌🏻

  • @kaiiemsawat2415
    @kaiiemsawat2415 Год назад +8

    For the first 1 hour. I would say that this is one of a very few tutorials that explains most (if not all) of the tools very well. Kudos to you!!!!!
    Ps. once I have time to learn more on this, I will surely update on how I feel about this video!!!

  • @viesi
    @viesi Год назад +10

    Would love to see the implementation with stripe

  • @Nofy89
    @Nofy89 Год назад +2

    Thank you for the tutorial! That's exactly what I've been looking for! I'm sure a Stripe tutorial would be great addition to your channel.

  • @beatbox1759
    @beatbox1759 11 месяцев назад +1

    Please Make a video of stripe integration, really loved this video learned a lot from this .
    your explanation is very easy to understand. Thank you

  • @phil5293
    @phil5293 Год назад

    Best Next.js tutorial I've ever seen. Very well explained. Thanks.

  • @saminhi3025
    @saminhi3025 Год назад

    Loved the content you produce for the nextjs community. Thanks to you, I have learned so much about project structure, database implementation and design skills. You are an amazing teacher, and you take time to explain concepts, which I am immensely grateful. Please make more projects with TypeScript, TailwindCSS, MongoDB and the PrismaORM, with Clerk authentication and nextAuth. I'm really enjoying these technologies, would love watching more

    • @codinginflow
      @codinginflow  Год назад +1

      Thank you for the kind words! Check out my latest tutorial, it uses these technologies!

  • @kaiiemsawat2415
    @kaiiemsawat2415 Год назад

    I finally follow up to the end of Cart page. So far, everything is very informative. I would say that I have been watching a few other tutorials, but the way you teach is the best (in my opinion).
    One thing I couldn't understand, with this high quality and detail oriented, how come only below 500 likes. Something must be wrong with people!!! You deserve much more than this!!!
    One of the things that made yours better is that you always (I think so) work on validations and make sure that there should not be any issue in various scenarios.
    I wish you create more of this type of video tutorial.

    • @codinginflow
      @codinginflow  Год назад

      Thank you for the kind words!

    • @brancode404
      @brancode404 Год назад

      Hey Florian Thankyou for the great contents. I was wondering if Next Js + Shopify would be a great real world production grade web app. Please do a tutorial on that.

    • @codinginflow
      @codinginflow  Год назад

      @@brancode404 I'll keep it mind

  • @ricardopompilio5390
    @ricardopompilio5390 Год назад

    Great stuff! Just finished deploying this app, really enjoying the content, looking forward to start on the whatsapp clone next, would love to see a continuation of this project with Stripe, thanks a bunch!

  • @Vancelott
    @Vancelott Год назад +1

    Thank you for this tutorial so much. I struggled with the creation of the search bar but your implementation works perfectly. Even if I wanted to follow a tutorial it was almost impossible with all the changes in nextjs :D

  • @vargabesz5000
    @vargabesz5000 11 месяцев назад

    Thank you for your hard work making this video! It is very well explained, structured and performed!

  • @devashishrai3458
    @devashishrai3458 Год назад +3

    I was searching this kind of tutorial. Huge thanks for providing this mate

  • @kaiiemsawat2415
    @kaiiemsawat2415 Год назад +1

    Finally done with the tutorial!! Awesome as always.
    Wonder if you would make a second part of this application where the users who create the items may edit and delete their items

    • @Vancelott
      @Vancelott Год назад +1

      the functionality of creating and editing is almost the same - when editing an item, you send a post request with the updated information, you just have to match the item using its id/slug

    • @kaiiemsawat2415
      @kaiiemsawat2415 Год назад +1

      @@Vancelott Thank you, will need to try that. It also should be a good practice as well

    • @codinginflow
      @codinginflow  Год назад

      You can do it with a server action

  • @ZockaRocka
    @ZockaRocka Год назад

    Thanks for the perfect Tutorial :) Love your vids!
    I just wanted to give a small hint: There is a really solid mongodb extension for vscode, so you can see your mongodb in vscode without the need to leave the editor.

  • @dixitGogoi32
    @dixitGogoi32 Год назад

    This is really a great video on NextJS 14 and the updated server actions

  • @lyricaldemon2537
    @lyricaldemon2537 8 месяцев назад

    Im building this Project next and I would love to see the Stripe implimentation because Im interested to build Businesses E-commerce websites and this Tutorial will be my gateway to building a lot of projects for clients
    Till everything clicks

  • @JamesBrown-nz1ow
    @JamesBrown-nz1ow Год назад

    @Coding in Flow thank you for putting in so much time and for all your hard work!!!

  • @BooksWeCanRead
    @BooksWeCanRead Год назад

    Wow! All the way through to production!! Man this is awesome I’m looking forward to this. Nice

  • @sarectua
    @sarectua Год назад

    Nice video. Adding stripe would have made it perfect :-). Trying to add it, but with anonynomous cart has me stumped for the moment. Thanks for sharing your knowlegde.

  • @Ayla20131
    @Ayla20131 Год назад +1

    Thank you so much for this tutorial!!! Perfect timing!!!! And finally tailwindcss🥳

    • @codinginflow
      @codinginflow  Год назад

      Haha yea I think I remember your last comment

  • @arshah246
    @arshah246 Год назад

    2:56:36 when i try to add existing product to cart it didn't increment the value instead it shows me error Unknown argument `quantity`. Available options are marked with ?. in my prisma quantity is Integer. How can i solve this issue

  • @sire_ns
    @sire_ns 8 месяцев назад

    Yo bro! please also make a video on integrating stripe in this project. This really was a good project, enjoyed every bit of it.

  • @samyisaac2543
    @samyisaac2543 Год назад

    Great project, I've learnt a lot from this project ❤

  • @xosnrdev
    @xosnrdev Год назад +1

    Really love it pls we waiting for the stripe tutorial love it ❤❤

  • @adarshrathi8265
    @adarshrathi8265 10 месяцев назад +1

    this video is very very excellent

  • @junmagic8847
    @junmagic8847 Год назад

    I have a question. how do you enable field level encryption with MongoDB such that only the user can see the notes but the administrator cant?

  • @levidamian2659
    @levidamian2659 Год назад +2

    Please make an update to this tutorial about how to use Stripe.

  • @HamzaKhan-ti6bw
    @HamzaKhan-ti6bw 10 месяцев назад +1

    I'm getting the error in lib/db/cart.ts:
    Error:
    Invalid `prisma.cart.findUnique()` invocation:
    Error converting field "updatedAt" of expected non-nullable type "DateTime", found incompatible value of "null".
    Anyone have any solutions?

  • @DevranDenizzz
    @DevranDenizzz Год назад

    Great tutorial.Thank you.i am still surprised how possible backend is simple and easy with server components like this...also really wondering where Nextjs is heading to..

  • @CaferElgin
    @CaferElgin Год назад

    Hello. I have a problem> my vscode is not suggesting autoimport for cookies() method which was introduced at 2:30:40 . I searched and tried many suggestions but still no luck. Autoimport for other modules work, except for next/dist/components/headers and react-icons as well. For cookies() method it suggests other methods or constants from next/dist/server/api... Any help is appreciated. Thanks

    • @codinginflow
      @codinginflow  Год назад

      Import it manually

    • @CaferElgin
      @CaferElgin Год назад

      @@codinginflow yeah I eventually did that 🤣.

  • @psyferinc.3573
    @psyferinc.3573 Год назад

    beyond amazing more and more comments as i follow through to the end

    • @codinginflow
      @codinginflow  Год назад

      thank you so much 😍

    • @psyferinc.3573
      @psyferinc.3573 Год назад

      @@codinginflow the nextauth SessioinProvider is giving me a runtime error. any advice because its frustrating for no reason. i even switched to nextjs 13-4-7 like you but it didnt work

    • @codinginflow
      @codinginflow  Год назад +1

      ​@@psyferinc.3573 what's the error message?

    • @psyferinc.3573
      @psyferinc.3573 Год назад

      Error: React Context is unavailable in Server Components
      @@codinginflow

    • @codinginflow
      @codinginflow  Год назад

      ​@@psyferinc.3573 Your code must be different to mine somewhere. Double check.

  • @xianyiliang6185
    @xianyiliang6185 Год назад +1

    Very well explained! The best Project using Next server action on YT so far, and one of the best Next13 project I've ever followed!
    There is one thing I didn't quite understand though. In 1:18:00 you mentioned that we have to use type here so that we can extend ComponentProps.
    From my understanding, we can still use interface by:
    ```
    interface FormSubmitButtonProps extends ComponentProps { // ... my own prop interface}
    ```
    Are there any difference here?

    • @codinginflow
      @codinginflow  Год назад +1

      Thank you for the compliment! I'm not sure about the interface right now. If it works, it works 👍

  • @RevathiG-o5d
    @RevathiG-o5d Год назад

    Thank you for this video. I'm new to Nextjs. How to take a build for this website?. I'm getting error while taking build like this Export encountered errors on following paths: /_not-found (all routes). Thanks in advance.

  • @TikTokTrendsCompilation
    @TikTokTrendsCompilation Год назад +3

    Amazing course! Also it's crazy to me how fast nextjs updates. I tried watching your nextjs tutorials from january and february 2023 and today in july everything is so much different, the entire structure so it's hard to follow along. I constantly have to keep watching your newest and latest tutorials.
    I'd like to see a Stripe integration tutorial as well as a real-time chat app, what do you think?

    • @codinginflow
      @codinginflow  Год назад +6

      Thank you! I am actually working on a real-time chat app tutorial right now!

    • @dirudeen1421
      @dirudeen1421 Год назад +1

      I would love to see the stripe tutorial as well

    • @codinginflow
      @codinginflow  Год назад +1

      @omjaju9251 No but I'll make one soon

  • @adxxtya
    @adxxtya Год назад

    I feel so bad watching such quality content tutorial for free :(

    • @codinginflow
      @codinginflow  Год назад

      You can pay it back by sharing it with someone 😁

  • @reactnative-fc8to
    @reactnative-fc8to 11 месяцев назад

    thanks you so much for this tutorial. and please can you explain how we can add Cron jobs to delete pending cart? thanks again

  • @nazokatisamova5073
    @nazokatisamova5073 Год назад

    Lol😂 ola muchachos was great to start the project ! Thanks for the hard work as well

    • @codinginflow
      @codinginflow  Год назад

      😆 I wanted to add some variation to my intros

  • @JatinBedi69
    @JatinBedi69 Год назад +1

    Add checkout / stripe functionality in same project

  • @anup_poud3l
    @anup_poud3l Год назад

    Can you add stripe integrations too? Thanks

  • @laxmiprasanna4092
    @laxmiprasanna4092 Год назад

    I think revalidation of path is not efficient for a complex UI. At 02:46:40 , you have revalidated the entire product page when you add that to cart. What if you have a complex UI with 50+ components ? Is there any better way ? Like in react client components using context or redux, when we have a state change only that one particular component updates or re-renders. Now in next js server comps we revalidate entire page . I dont like it.

    • @codinginflow
      @codinginflow  Год назад +1

      Revalidating the data doesn't have any impact on rendering. It doesn't matter how complex your UI is. React always rerenders efficiently.

    • @laxmiprasanna4092
      @laxmiprasanna4092 Год назад

      @@codinginflow thank you. I thought revalidating is like refreshing the page.

  • @EnglundsFamily
    @EnglundsFamily Год назад

    Great and I'll vote for adding cart-checkout and stripe or PayPal. 🙏❤

    • @codinginflow
      @codinginflow  Год назад

      noted

    • @brancode404
      @brancode404 Год назад

      ​@@codinginflowplease add categories page and quantity on individual product as well brother

  • @davecsimp
    @davecsimp Год назад +1

    Damn, you are strong 💪

    • @codinginflow
      @codinginflow  Год назад +3

      Years of Android development toughened me up 😎

  • @psyferinc.3573
    @psyferinc.3573 Год назад

    thank you very much man
    you really set things up for us

  • @techchannel0
    @techchannel0 Год назад +1

    Stripe tutorial please and thank you! :D

  • @비블-l7x
    @비블-l7x Год назад

    always, Thank you so much. server action is interesting

  • @ayushshende4290
    @ayushshende4290 Год назад

    Does server actions replace the route handlers, if not when to use which one. Also this approach has both the frontend and backend code intermixed which contradicts the earlier idea that we should keep both code separate, a little thoughts on that would be helpful as well

    • @codinginflow
      @codinginflow  Год назад

      Yes, it replaces route handlers. And your doubt is true. I guess it depends on the size of the project.

  • @TikTokTrendsCompilation
    @TikTokTrendsCompilation Год назад

    one more question, im connected to my android phone's hotspot that uses 4g internet, so im not connected to my home wifi. when i try to login via google sign in it keeps throwing an error callback saying "try signing in with a different account". No errors in console. Just forbids me for signing in with google. I guess this has something to do with me being connected on a hotspot network?
    do you have any idea what could it be? what can i try to fix this?

    • @codinginflow
      @codinginflow  Год назад

      Check the logs in VS Code to see if there is an error

  • @adamjames8732
    @adamjames8732 Год назад

    1:10:54 any way to bring zod with the html form

    • @codinginflow
      @codinginflow  Год назад +1

      Yes. You can make the form a client component and then use anything you like (like React hook form with Zod)

  • @BISHWA1234
    @BISHWA1234 Год назад

    Can you please extend it further to multi vendor app

  • @n-o-i-d
    @n-o-i-d Год назад

    Every time I see a new video from you I think... "damn! Much respect for him for escaping the Android hell cage"

  • @kaimuljewel24
    @kaimuljewel24 Год назад

    When I try to add a product I get this error message
    Invalid `prisma.product.create()` invocation.
    Please help

  • @GregPeters1
    @GregPeters1 Год назад

    Awesome! Thank you

  • @happydaydaniel
    @happydaydaniel Год назад

    Thanks for this tutorial. I got a popup in my IDE to update my Prisma and Prisma client from 4.16.1 to 5.0.0. Will this not affect the way we integrate with mango database and other things?

    • @codinginflow
      @codinginflow  Год назад +1

      I haven't read the release notes on Prisma 5.0 yet but I assume there won't be much change necessary

  • @titioluokun8360
    @titioluokun8360 7 месяцев назад

    wellDone, this is great, you are wonderful; i guess the serverActions are no more in Alpha again...i guess all the bugs are fixed now...like this? "await new Promise(r => setTimeout(r, 3000)) "

  • @mileicampeonmundial
    @mileicampeonmundial Год назад

    does it make sense to make as little client components as possible? wont incur in higher costs?

    • @codinginflow
      @codinginflow  Год назад

      Yea, I think that's a good practice. But one shouldn't worry about it too much. Before the app router, all components were client components.

  • @Incomingsign
    @Incomingsign Год назад

    i am facing issue. when i add one product to cart and goto cart page it shows that product. again if i go back to home page and add another product and then go to cart, that second product didnt show up until i refresh cart page.

    • @safariambience4052
      @safariambience4052 Год назад

      I am experiencing the same issue

    • @codinginflow
      @codinginflow  Год назад

      That's weird because revalidatePath should invalidate the router cache 🤔

  • @TikTokTrendsCompilation
    @TikTokTrendsCompilation Год назад

    alright i completed the tutorial successfully now. great code quality and explanation! now this is my first time working with prisma and in depth of nextjs. i usually built backend with aws. and i saw no backend being built here, everything was used "as a backend" with prisma ORM? how does this work? have we just built the backend entirely.. on the frontend? no need for aws, cloud services etc?

    • @codinginflow
      @codinginflow  Год назад +1

      Basically, yes. Next.js is a full-stack framework that includes both the frontend and backend. Server components and server actions are executed on the server :)

  • @MrElio74
    @MrElio74 Год назад

    Really enjoy your videos. Still unclear why did you use Prisma instead of native libraries and tools? Just curious. Also, everyone talks about caching issues with new Next Js 13.4 Would you add more on this if you were to shoot this video now?

    • @codinginflow
      @codinginflow  Год назад

      The native MongoDB driver is not very popular. Calling revalidatePath in a server action invalidates the local client cache and should fix the caching issue. There are some situations where caching is still a problem but they shouldn't apply to our project here.

  • @asucho
    @asucho Год назад

    love your videos, any chance you livestream a game making session on unity or some other platform?

  • @leunamvon2565
    @leunamvon2565 Год назад

    Hey Florian, one issue, very nice tutorial but the /cart/page.tsx is not triggering the const cart = await getCart(), somehow that line is not being read. Can you please give some light about this? Thanks in advance!

    • @codinginflow
      @codinginflow  Год назад

      You need to read the error message

    • @leunamvon2565
      @leunamvon2565 Год назад

      @@codinginflow There is no error message, it’s just not being triggered. It is only being executed the first time, the second time is not being executed, somehow looks like it’s cached or something, like I would need a useEffect…

    • @codinginflow
      @codinginflow  Год назад

      @@leunamvon2565 Did you implement the part where we read from the cookie or the auth state?

    • @leunamvon2565
      @leunamvon2565 Год назад

      @@codinginflow yes, I arrived to the part where the cart page is ready, so we read the cookie to get the cart from mongo, the thing is when you add an item in the product page and you click view cart, the cart page somehow doesn’t shows the new added item/items, when you reload the page then it appears.

    • @codinginflow
      @codinginflow  Год назад

      @@leunamvon2565 That's weird. Are you using the same Nextjs version as I do?

  • @ryanpratama14
    @ryanpratama14 Год назад

    BIG THANKS!

  • @bhargavkumar
    @bhargavkumar Год назад

    Do I need any previous working experience in prisma or anything to start?

    • @codinginflow
      @codinginflow  Год назад +2

      No. You just need to watch my Next.js 13 beginner tutorial first.

  • @skyhappy
    @skyhappy Год назад

    Why not use postgres over mongodb? SQL should be used for structured data like ecommerce stores where products belong to a store, orders to a user, etc.

    • @codinginflow
      @codinginflow  Год назад

      What problems did you run into with MongoDB here?

  • @andyfifedenim
    @andyfifedenim Год назад +1

    i would like to see a Stripe implementation video thanks

  • @conpororo
    @conpororo Год назад

    Hola muchachos hahahaha nice, i'm native spanish, that was funny xd

    • @codinginflow
      @codinginflow  Год назад

      I actually meant Hola amigos 🤣

    • @conpororo
      @conpororo Год назад

      @@codinginflow pero tambien esta bien dicho

  • @Maifumei
    @Maifumei Год назад

    Copy your code, but for some reason, my 'use server' reported an error,At add-product

    • @codinginflow
      @codinginflow  Год назад

      Don't copy the code, follow the tutorial

    • @Maifumei
      @Maifumei Год назад

      @@codinginflowYes, I started by following your tutorial. On the add product page, the "use server" error was reported and I copied the code. It may be that I did not install any other supported features, so I will look back again.

    • @codinginflow
      @codinginflow  Год назад

      @@Maifumei What error message are you getting?

    • @Maifumei
      @Maifumei Год назад

      @@codinginflow The prompt is: x To use Server Actions, please enable the feature flag in your Next.
      Then I read the document and it was only possible to use it together with the form action. I used shadcn/ui and changed the form to a form, but it didn't work.。

  • @AdityaEditzYT
    @AdityaEditzYT Год назад +1

    Huge request to make projects of Jetpack compose android apps from beginner

    • @codinginflow
      @codinginflow  Год назад +5

      There will be no more Android tutorials on this channel, please stop requesting them.

    • @AdityaEditzYT
      @AdityaEditzYT Год назад +1

      @@codinginflow okay then we are unsubscribing okay and disliking too

  • @dmytro.turskyi
    @dmytro.turskyi 9 месяцев назад

    I want to see a stripe tutorial.

  • @htcsaj7876
    @htcsaj7876 Год назад

    Nice work. Where is the payments. PayPal or anything else

  • @bhargavkumar
    @bhargavkumar Год назад

    Please make a complete course on Nextauth and Supabase with a real life project.

    • @codinginflow
      @codinginflow  Год назад

      Supabase has its own auth solution so you don't need next-auth

  • @psyferinc.3573
    @psyferinc.3573 Год назад +1

    please add prisma as well in the title .

  • @andrsh9388
    @andrsh9388 Год назад

    nice!!

  • @jaymartinez311
    @jaymartinez311 Год назад +1

    Stripe tutorial please.

  • @tobisamuel8940
    @tobisamuel8940 5 месяцев назад

    stripe tutorial video please 🙏🏾

  • @vramosjd
    @vramosjd Год назад

    following this and yes please make an update for adding stripe

  • @mohammedarshadhassanabdurr8644
    @mohammedarshadhassanabdurr8644 Год назад +1

    Need Stripe tutorial!

    • @codinginflow
      @codinginflow  Год назад

      noted! But only if you leave a like on the video

  • @dicey2030
    @dicey2030 Год назад +1

    Please Integrate with Stripe I m quite interested to watch it ... @Coding in Flow

  • @TikTokTrendsCompilation
    @TikTokTrendsCompilation Год назад

    in schema.prisma, what is the difference between annotating specific fields with @unique and on top of that at the bottom of table include @@unique([token]) on the same field that was already annotated with @unique?

    • @codinginflow
      @codinginflow  Год назад +1

      Good question. I don't know, I copied that snippet from the Next-auth docs. But you're right, the unique token should be enough.

  • @wahabch1223
    @wahabch1223 Год назад

    Where is final code?

  • @rasputinmoore
    @rasputinmoore 8 месяцев назад

    and now the second part: Payment Gateaway!

  • @rishiraj2548
    @rishiraj2548 Год назад

    🙏👍👍

  • @paulumeh4187
    @paulumeh4187 Год назад

    the github link thanks

  • @zeus433
    @zeus433 Год назад

    Brain is on smokes here

    • @codinginflow
      @codinginflow  Год назад

      why 😆

    • @zeus433
      @zeus433 Год назад

      @@codinginflow 😅 it's quite complex, the whole data flow structure, but it's sinking in thanks to your concise explanations. When I'm done I will try to redo it by building my own 🤞.

    • @codinginflow
      @codinginflow  Год назад

      @@zeus433 nice 👌

    • @zeus433
      @zeus433 Год назад

      @@codinginflow Also, w/ my beginner struggles aside. I gotta admit, I'm highly impressed by how simplified the whole process was, thanks to the new NextJS 13 and Prisma, not to mention Tailwind CSS and DaisyUI.. It's going to be a lot of fun building websites with these. Such a good time to be returning to web development.

    • @codinginflow
      @codinginflow  Год назад +1

      @@zeus433 I agree. That's why I have several side projects 😃

  • @sushilbajpai3082
    @sushilbajpai3082 Год назад +1

    Stripe it bro 🥹

  • @raki0125
    @raki0125 Год назад

    Pls smile

  • @chandershekhar959
    @chandershekhar959 Год назад

    omg

  • @lycan2494
    @lycan2494 Год назад +14

    Look at dem muscles. Dude prolly eatin good from the 💰 he earned from his full stack course 😂

    • @codinginflow
      @codinginflow  Год назад +4

      Nah I'm always hungry 😂

    • @zeus433
      @zeus433 Год назад +2

      Full stack muscles

  • @ramziosta
    @ramziosta Год назад

    I am stuck with the UserMenuButton component getting this error :
    ⨯ Error: Functions cannot be passed directly to Client Components unless you explicitly expose it by marking it with "use server".
    ^^^^^^^^^^
    I am not finidng help with fixing this errrot

  • @lippycruz3819
    @lippycruz3819 Год назад

    onlyfans when

  • @Incomingsign
    @Incomingsign Год назад

    in Navbar.tsx where u called await getCart(). what if there is no cart id exist in cookies. the whole code broke. and if we use createCart in Navbar.tsx it throws "cookies can only be modified in server actions"

    • @codinginflow
      @codinginflow  Год назад

      We create the cart when we add an item, not in the navbar.

  • @reactnative-fc8to
    @reactnative-fc8to 11 месяцев назад

    thanks you so much for this tutorial. and please can you explain how we can add Cron jobs to delete pending cart? thanks again

  • @_techbk
    @_techbk Год назад +1

    Stripe tutorial please