Тёмный

Micro-Frontends in Just 10 Minutes 

Jack Herrington
Подписаться 185 тыс.
Просмотров 230 тыс.
50% 1

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

 

23 сен 2024

Поделиться:

Ссылка:

Скачать:

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

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 381   
@adarshpandya
@adarshpandya 2 года назад
Hey jack, amazing content! These concepts are too tough for beginners though 😂 can you give simple example of what basically microfrontend is
@jherr
@jherr 2 года назад
A micro-frontend is a shared piece of UI code at (using the Atomic UI leveling) the "organism" level. Meaning that it's a self-contained UI that manages its own state and interaction with the customer. Though it can also interact with the host container.
@omarkarim9298
@omarkarim9298 2 года назад
This channel isn’t exactly for beginners!
@Brunoenribeiro
@Brunoenribeiro 2 года назад
His past videos dive deep in the concept :)
@CFXTBogard
@CFXTBogard 2 года назад
Jack's playlist answers all your questions regarding that.
@PeerReynders
@PeerReynders 2 года назад
"Micro frontends is an approach where a web application is broken up by its pages and features, with each feature being owned end-to-end by a single [microservice] team." (Thoughtworks 2016 Technology Radar) What this video describes is using module federation as a cross-framework reuse mechanism - which only has some relevance to "SPA/PWA Composition" micro frontends. From: code.talks 2019, "Patterns for Micro Frontends" by Erik Dörnenburg. Anti Pattern: Cross-service Data Loading - An SPA/PWA that loads one monolithic JS bundle and then queries each service separately (or through an API gateway). Issue: The goal with microservices is to have autonomous teams which maintain loosely coupled services. Ideally each micro service has full, autonomous control over the client facing representation of the service. A monolithic frontend makes it impossible for a service's client facing representation to be updated independently of everything else. Fix: Patterns for Micro Frontends: 1. Web Approach - Each microservice has it's own page so each page is a micro frontend. 2. Server-Side Composition - The micro frontend for a microservice is injected via a server side include (SSI) or edge side include (ESI). Example: "A High-Performance Solution to Microservices UI Composition" by Arif Wider & Alexey Gravanov regarding the AutoScout24 Project Tatsu. 3. Client-side Composition - The microservice renders an HTML partial/fragment which is returned to the browser to be spliced into the DOM. 4. Client-side Rendering - The microservice returns JSON and JS to render it to the browser which uses both to complete the render into a static page. 5. SPA/PWA Composition - Here the microservice specific JSON/JS is rendered by an SPA/PWA instead of a static page. This differs from the "Cross-service Data Loading" anti-pattern because each service supplies the JS responsible for rendering the service's JSON - i.e. the rendering JS is not included in SPA/PWA bundle (doesn't matter if the bundle is code split).
@mccall7122
@mccall7122 2 года назад
Holy crap. This was one of those rare times where a video is just great all the way through. No BS, just pure content. High quality content.
@amansaxena4446
@amansaxena4446 2 года назад
Absolutely GOLD content for free available and just 31k views WHY? i know the topics which he covers are quite advanced and one might not able to catch up but still pls share this channel a lot could be learned from Sr. Devs like him. Lots of love from India
@claudioseccia9380
@claudioseccia9380 2 года назад
This is awesome. I'm currently integrating an application with a frontend bus using iFrames, due to company specifications. I think this solution is a game changer. Thanks (also for all the other videos)!
@jherr
@jherr 2 года назад
This solution is very much a game changer.
@jakhongirabdukhamidov2796
@jakhongirabdukhamidov2796 2 года назад
Phenomenal, I had spent crazy time tryna figure this out and even took a Udemy course which was outdated, but this video met all my needs in just 10 mins. Huge respect
@Ca-rp7bv
@Ca-rp7bv 11 месяцев назад
Senior content is always hard to find, thanks very much for being different
@Astral_Dusk
@Astral_Dusk 6 месяцев назад
Just got tripped up on an interview with this term, absolutely essential to know. I've always used the "modular development" umbrella term for both components (that can make up a micro frontend) and micro frontends (that make up a complete application frontend).
@garywaddell6309
@garywaddell6309 2 года назад
Hey Jack! I searched RU-vid for Module Federation with React and saw your posts, have never seen them before. I purchased a Udemy course on micro front ends that drags on so long for far too many hours and is very soon outdated, but your videos are so direct and to the point, no BS fluff, really like your style and explanation. Thanks for sharing this info, it’s super helpful, glad to start watching more of your vids 🙌🏻
@kamertonaudiophileplayer847
@kamertonaudiophileplayer847 2 года назад
I use a micro frontend technology since 2000. It is certainly cool technology and I created dozen apps on it. I am glad that more people started using it now.
@TheArkadyuti
@TheArkadyuti 4 месяца назад
Thank you sir, I have an upcoming HLD meeting in next 2 hr and I really needed this
@turokII
@turokII 2 года назад
Great content Jack, thank you! I’m currently importing several npm modules made with TSDX, but will be giving this approach a try
@fagundezantony2358
@fagundezantony2358 2 года назад
Hi Myles!! there is a lot of us, are you using plain rollupjs?? PD: I'm in the same situation. PD: sorry for my bad English 😅😅
@Dev-Phantom
@Dev-Phantom 4 месяца назад
Best video for a basic understanding of micro frontends.
@theworld5937
@theworld5937 2 года назад
This guy is the best developer instructor I have ever seen.
@clouatre3034
@clouatre3034 2 года назад
Man, this rules. THANK YOU! Game changer for a lot of my future work.
@marcelinoborges5088
@marcelinoborges5088 Год назад
I have never this explained so simple like you did. Great video!
@ram-bk4mu
@ram-bk4mu 2 года назад
Great video quality!! You are one of the best programmers that I have found on the RU-vid :)
@ngochunglongnguyen4523
@ngochunglongnguyen4523 Год назад
Awesome demonstration 🎉 and cool concept. It's really useful when the company wants to move gradually from one framwork to another.
@theprodev
@theprodev 2 года назад
Amazing content. So great to see this, and the cross framework example was spot on. Hoping to put these concepts into work soon.
@SwiftySanders
@SwiftySanders 2 года назад
Ok you sold me on this with this video. I need to schedule some time to study this each week.
@shubhasingh7583
@shubhasingh7583 2 года назад
10 mins of great content, thank you for all your effort.
@rodrigomoura2108
@rodrigomoura2108 Год назад
This channel is the gold man. I'm impressed with the quantity and quality of our videos. Thank you for sharing.
@Hitotsuday
@Hitotsuday 2 года назад
Great explanation, wish I had this back in 2018. I tried to sell the idea of micro-frontend to my team, but they didn't understand it; didn't help that I only had 3 months of experience
@10x-developer
@10x-developer Год назад
New stuff, good stuff, and also web presented greetings from Lithuania 🇱🇹
@AlexCrudu
@AlexCrudu 2 года назад
HOW DID I NOT STUMBLE ON YOU BEFORE! Amazing content. Thanks!
@jherr
@jherr 2 года назад
Blame RU-vid. 😂
@Luxcium
@Luxcium Год назад
I did an online course on Udemy it was amazing but you sum all that in 10 minutes… I mean it would all have been Chinese 🇹🇼 to me [sic’] without the course 😅but at the same time it is just easier to understand with your explanation I wish I could have got that overview earlier in my learning process 🎉 🎉🎉 🧧🐰🇨🇦🇻🇳 Happy new year 🇨🇳🇭🇰 🥮🐇🧨🏮
@dattugaade
@dattugaade 2 года назад
Awesome video. Explained in an easy way with simple example. Thanks
@yassinebouchoucha
@yassinebouchoucha 2 года назад
cross Framework App ! that's what we 've been waiting for.
@aminomar7890
@aminomar7890 2 года назад
Easy peasy as you say :) have you a plan to talk about your long experience with different programming languages, and the best programming language from your point of view, cons and pros, what about functional programming language and its important, ….etc.
@jherr
@jherr 2 года назад
I hadn't really planned on it. I'll keep it in mind tho.
@thiccboi6211
@thiccboi6211 2 года назад
papa Jack back at it again with another great video! Amazing one. I stopped Module federation implementation in our project last year since its made of webpack 4 CRA apps and moving things to webpack 5 was not stable and leaked memory all the time. Maybe its time to look at it again.
@ralphlargo9728
@ralphlargo9728 Год назад
You saved my job again Jack, thank you 🎉
@LahiruKurukulasuriya
@LahiruKurukulasuriya 2 года назад
I became a fan of you since I watched MFEs using single spa video
@aileenchan3741
@aileenchan3741 2 года назад
Woah, so much information here! Will do some research on micro-frontends! Thank you! : D
@lixiao2882
@lixiao2882 2 года назад
Thanks Jack! Your 2-hour tutorial posted by freecodecamp gave me confidence in navigating our switch from monolith to micro-FEs. Coffee on me!
@jherr
@jherr 2 года назад
Thank you so much!
@Micsc
@Micsc 9 месяцев назад
Thanks, I have to dive deeper into this stuff.
@Drvo3
@Drvo3 2 года назад
This is extremely good content. Finally something worth to watch. Great explanation and clarity of the topics.
@RavindraSingh-lp9pl
@RavindraSingh-lp9pl 4 месяца назад
plz create more such advanced topics
@fagundezantony2358
@fagundezantony2358 2 года назад
Hey Jack!! Your content is amazing!!! Thanks for sharing this! Greetings from Argentina!
@dars1816
@dars1816 2 года назад
it's like magic wtf
@chrissullivan331
@chrissullivan331 2 года назад
Thanks for the tutorial Jack, informative as always.
@RobertoGPuentesDiaz
@RobertoGPuentesDiaz 2 года назад
Great Video Tutorial. Cheers from Argentina
@albo4life6082
@albo4life6082 2 года назад
U are so amazing. I love people that put their all into things they love 💯💯
@lechos5245
@lechos5245 3 месяца назад
Wow, absolutely fantastic!
@alexandrkositsky7698
@alexandrkositsky7698 Год назад
Big thanks for video 🔥 Very clear explanation
@niloneregato5097
@niloneregato5097 2 года назад
Great job Jack. Nice tool!
@DevAditya
@DevAditya Год назад
😳😳😳 Shocked! It's amazing BTW 😍
@matthew1106
@matthew1106 2 года назад
Gold! This is so valuable. Thank you for sharing you knowledge.
@matthew1106
@matthew1106 2 года назад
Jack my only question here is for the host/shell application can we handle ALL routing at that level for the remotes?
@jherr
@jherr 2 года назад
Yeah.There is a pattern called Full Site Federation that allows you to wire an entire site together using Module Federation. It's pretty intense: ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-W0RbrAZtj7I.html
@matthew1106
@matthew1106 2 года назад
@@jherr thanks!
@miguelship3
@miguelship3 Год назад
This is next level of coolness man!!
@kevinrobertandrews
@kevinrobertandrews 2 года назад
Hey Jack, cool video! I've never considered building microfrontends. Could you please describe some real-world use cases for this type of architecture?
@jherr
@jherr 2 года назад
Sure. Dashboard widgets are micro-frontends. Shared header/footers. Cart UIs in eCommerce applications. Those are just a few thoughts. Basically anywhere you want multiple teams to contribute to a single page.
@stevenrankin9056
@stevenrankin9056 Год назад
@@jherr Getting confused by using module federation to build MFEs versus Web Components. Do you have any content which addresses this? Thx
@jherr
@jherr Год назад
@@stevenrankin9056 Web Components are a perfectly good MFE architecture to use. Really just depends on your requirements and the level of integration you want between the host application and the MFE.
@saikun0293
@saikun0293 2 года назад
This video is a gem! Thanks for the content
@clebsgaming92
@clebsgaming92 Год назад
Amazing content, thank you very much Jack!
@GabrielRUrbina
@GabrielRUrbina Год назад
Maybe a hot take Being able to deploy a fragment of an application independently is cool, HOWEVER deploying fragments of an application without testing its interactions is DANGEROUS. In microservices you can deploy independently because you can test independently because they fail independently (one microservice cannot break another microservice). In microfrontends you can deploy independently, but you cannot test independently, because one microfrontend can break another microfrontend in a myriad of ways: - The DOM - Stopping events - CSS - URL - Storage - Cookies - Global Javascript scope As far as I know Iframes are the safest, the leave room for storage and cookies issues, but the performance and accessibility is thrash. I'm I wrong? is there a way to GUARANTEE that microfrontend A CANNOT break microfrontend B?
@jherr
@jherr Год назад
There is as much of a "GUARANTEE" with microfrontends as there is with microservices. Being able to test a microservice in isolation (which you can do with a microfrontend) is no "GUARANTEE" that microservice A won't change its behavior in a such a way that microservice B that was depending on that behavior will break. In the same way that even a patch version change in a library can break that app that consumes it. Have good contracts, use the same component oriented framework across all the MFEs and apps. Make sure the versions are synced. Share as little state (preferably none) as possible. Don't use MFEs for mission critical behavior. These are the best practices that keep MFEs reasonable.
@GabrielRUrbina
@GabrielRUrbina Год назад
@@jherr I agree that for non critical uses "reasonable" stability is a fair price to pay for rapid deployment I'm also under the impression that a lot of developers are not fully aware that there is no guarantee of independent failure when deploying a microfrontend and do not have automated integration tests to cover these cases Thanks for your reply 👍
@jherr
@jherr Год назад
@@GabrielRUrbina No worries. I should have added e2e tests during CI/CD which can also uncover a lot of issues.
@haquocviet9253
@haquocviet9253 2 года назад
wow, so amazing. thanks your for open my eyes
@PiyushChauhan2011
@PiyushChauhan2011 2 года назад
Amazing, my cents for the book already
@DaggieBlanqx
@DaggieBlanqx 6 месяцев назад
This video is on point! Thank you!
@alinawaz4034
@alinawaz4034 2 года назад
Amazing video, Very good teaching style
@sourabhvaishnav8235
@sourabhvaishnav8235 Год назад
He is the JACK of ALL.
@matts8857
@matts8857 2 года назад
Awesome stuff as usual Jack!
@deficx
@deficx 2 года назад
Module federation seems like such a next-level feature, but it feels so clumsy with Angular which is a bit bummer (or maybe there's a gap in my knowledge). I can't seem to find a proper way to use exposed components without using lazy loaded modules with Angular Router. Every example and repo seems to either use some directive to "create" the remote component, or a wrapper component to do the same. Looks so simple and clean with React/SolidJS though!
@jherr
@jherr 2 года назад
I think it's the dependency injection that makes it harder to get Module Federation running on Angular. You end up having to work around that a lot.
@danielpuerta2386
@danielpuerta2386 2 года назад
Really, really amazing explanation!! 🎉
@franklinendaya9906
@franklinendaya9906 2 года назад
Great intro on microfrontends! Can you also cover topics on how to share states between microfrontends in the future?
@marcelinorguez
@marcelinorguez 6 месяцев назад
Useful and well explaned. Cheers!
@daytcg3186
@daytcg3186 2 года назад
Thank you It’s easy to be understood,
@MrJellekeulemans
@MrJellekeulemans Год назад
Thats awesome. I feel stupid for messing around with s now 😁
@KriztianEinsamkeit
@KriztianEinsamkeit 2 года назад
Regardless of the content, which is excellent by the way, your explaining skills are exceptional. Thank you very much for taking the time to explain us this topic. Certainly I subscribe, of course I subscribe.
@morningstarsci
@morningstarsci Год назад
the idea behind this is that parts of the front-end could be maintained separately by different teams. doesn't this make testing more difficult because it obscures end usage and creates yet another place for team communication and planning to break down?
@yusufansari7618
@yusufansari7618 2 года назад
You are the gem jack!!!
@kettenbach
@kettenbach 2 года назад
Another banger Jack my Boy. Great content. Thanks for sharing. How can we work webassembly and rust in to this 🤔
@jherr
@jherr 2 года назад
Challenge accepted. 😂
@RobertoFabrizi
@RobertoFabrizi 2 года назад
Amazing Jack, I was wondering if you could do a deep dive on MFE using module federation, for example how the composition is made, how to handle one portion of the page being offline (is it called circuit break in this case too?), how to propagate for example a JWT with the currently logged user for auth handling, like which buttons are grayed out etc. I saw some material accross multiple sources, but they pale in comparison to your clarity and quality...
@jherr
@jherr 2 года назад
Many of those questions are answered in the videos in the Module Federation playlist: ru-vid.com/group/PLNqp92_EXZBLr7p7hn6IYa1YPNs4yJ1t1 Also, a federated module cannot be "offline", that's a common misconception. A federated module is just JavaScript code. So it should be deployed on an asset store (e.g. S3) just as you would any JavaScript module. So in order for it to be "down" S3 would need to be down. That being said, if you are super worried about that there are error boundaries and other mechanisms you can use.
@RobertoFabrizi
@RobertoFabrizi 2 года назад
@@jherr Awesome, thank you so much and I cannot wait for the next content
@mdminhazahamedrifat3282
@mdminhazahamedrifat3282 Год назад
Such a wonderful video. Thumbs up
@MrCoolByte
@MrCoolByte 2 года назад
How well does typescript play with this? since the code is pulled at runtime, I'm guessing you won't get type info on the host right?
@jherr
@jherr 2 года назад
I have a video on that in the playlist. Basically you need to have a shared "contract" declared interfaces in an NPM module that is brought into both the host and the remote. Because, yeah, you're right, at the point where the TypeScript is compiled into JS the types are gone. And even if they weren't gone tsc has no capacity to grab some types from remote code. I should probably update that video now that I've got a lot more TS experience.
@MrCoolByte
@MrCoolByte 2 года назад
@@jherr Thanks alot for your prompt response. I hope you channel gets the attention it deserves, really one of the best coding channels out there.
@zacharywagner3519
@zacharywagner3519 2 года назад
Jack thank you for the great vids! Some of the best module federation content I can find. Any plans on making create-mf-app more production-ready? Also, would love to get some details on your VS Code setup. Cheers!
@jherr
@jherr 2 года назад
create-mf-app is meant to just create POC applications so that you can then simulate enough of your production setup to test whether using Module Federation makes sense, and how you would architect it. We are adding some very basic stuff to it, like .gitignores, but probably not much past that.
@TheDorac1
@TheDorac1 2 года назад
This was amazing! Thank you.
@jr-hp7er
@jr-hp7er 2 года назад
Wow, Jack! Amazing ❤️🙌
@ParthaSarathylink
@ParthaSarathylink 11 месяцев назад
Great explanation
@natanloterio
@natanloterio 2 года назад
That was so cool, thank you
@SebastianVuye
@SebastianVuye 2 года назад
Great explanation, thanks!
@davidk.6834
@davidk.6834 Год назад
Sick transition 😂
@eferesen
@eferesen 2 года назад
Thanks so much!
@sagarreddy7461
@sagarreddy7461 2 года назад
It's amazing, zing zing jack. Thanks!
@GiriJeedigunta
@GiriJeedigunta Год назад
Hey Jack, This is fantastic. Learned a lot about micro-frontends in 11 mins that any other source /course. Would you have an example with NX instead of yarn workspaces :)
@kamilkuriata1747
@kamilkuriata1747 2 года назад
Great explanation :)
@alisanad9048
@alisanad9048 2 года назад
Thank you, you're amazing!
@afrikanonyma
@afrikanonyma Год назад
You just got a new subscriber ... great !
@nikhilprabhakar7116
@nikhilprabhakar7116 Год назад
Thanks!
@abhisheksharma9796
@abhisheksharma9796 2 года назад
Great video Jack. I have been meaning to implement this for a long time as our Frontend has ton of services. One question though: how do these apps share state, e.g Authentication states and stuff
@jherr
@jherr 2 года назад
You can check the playlist and the book, there are a ton of options there. Anything from simply subscribe to some RxJS observable hung off of window, all the way through state managers like Redux, Jotai, etc. They all work.
@helloworld2740
@helloworld2740 2 года назад
Just too awesome channel
@fadiliabdeljalil770
@fadiliabdeljalil770 2 года назад
Great tutorial, Thanks
@DuyTran-ss4lu
@DuyTran-ss4lu 2 года назад
Super awesome. Thanks
@JoanJimenez
@JoanJimenez 2 года назад
This is brilliant.
@kaizhu1702
@kaizhu1702 2 года назад
Great video, Jack. I just curious does all the apps have to run Webpack the same time to make this happen?
@jherr
@jherr 2 года назад
They all have to be bundled by Webpack 5. There is a rollup module federation plugin, but I think it can only consume federated modules.
@MarkDekkersLife
@MarkDekkersLife 2 года назад
This is freakin awesome
@halffull6279
@halffull6279 2 года назад
Great tutotial
@hamburger-fries
@hamburger-fries 2 года назад
Loving this content!
@the_coder241
@the_coder241 2 года назад
🔥🔥🔥🔥 love it!!
@antoncaballes1846
@antoncaballes1846 2 месяца назад
Hello Jack I really love to watch your videos. I have a question about this topic. May I know when to use micro-frontend? Or what is the importance of it? Thank you.
@aseep0109
@aseep0109 2 года назад
WOOWW it's greatt!!! thx Jack!!!!!
@estebanburgos
@estebanburgos 2 года назад
Hey Jack! Awesome video again. I'm waiting for one MF example with nextjs 11 ssr, today nextjs only can use csr with the last version of @module-federation/nextjs-mf but ssr no yet. Do you have any solution? Thank my friend
@jherr
@jherr 2 года назад
I don't have anything for you on SSR/MF on NextJS. Honestly, I'm not really spending a lot of time on SSR myself. Most of the applications I work on are either CSR or SSG. If the SSR story becomes clearer I'll definitely cover it, but really the only hope is pushing Vercel to finally take Module Federation seriously. Thankfully general interest in MF is increasing because Micro-FEs are becoming more popular. At some point we are either going to get a Micro-FE ready framework and either that's going to be NextJS, or a competitor, which would push Vercel to support MF to compete.
@estebanburgos
@estebanburgos 2 года назад
@@jherr thanks so much for your response. Of course the best way will be that vercel make magic directly in nextjs. For now I'm looking for an alternative solution like a nextjs-mf from Zack Jackson but I need to paid for check this solution.
@jherr
@jherr 2 года назад
@@estebanburgos If you are looking at this just personally you might want to reach out to Zack directly to see if he can give you a break on the $12 price tag. If this is for a company then they should be able to handle $12 for you to check whether this solution is enough for your needs.
@estebanburgos
@estebanburgos 2 года назад
@@jherr yes of couse, I'll contact him. Thanks for the information, I will see you in your next video 😀!
@faviocabral2675
@faviocabral2675 2 года назад
this its a crazy video of microservices
@cannotthinkofanybetterhandle
Very cool!!
@fazilfaz-mq5uj
@fazilfaz-mq5uj 2 месяца назад
I am faced issue with host the color of tailwind is not reflecting in remote its working fine done correctly given in the video
Далее
Fixing Module Federation Versioning
9:31
Просмотров 16 тыс.
Vite and Module Federation Makes Micro-Frontends EASY!
27:36
The joker favorite#joker  #shorts
00:15
Просмотров 13 млн
У БЕЛКИ ПОЯВИЛИСЬ КОТЯТА#cat
00:20
Micro-Frontends: What, why and how
9:39
Просмотров 156 тыс.
Goodbye, useEffect - David Khourshid
29:59
Просмотров 500 тыс.
ShadCN’s Revolutionary New CLI
12:11
Просмотров 46 тыс.
Mastering React Memo
26:56
Просмотров 135 тыс.
Five Module Federation/Micro-Frontend Mistakes
28:09
Просмотров 48 тыс.
The joker favorite#joker  #shorts
00:15
Просмотров 13 млн