Webpack Module Federation in-depth w/ Zach Jackson

  Рет қаралды 5,549

Kevin Ghadyani - JavaScript

Kevin Ghadyani - JavaScript

Күн бұрын

Пікірлер: 18
@fabriceekpetse6440
@fabriceekpetse6440 3 жыл бұрын
Very helpful. Especially the bootstrap file. Thanks guys for working on making DX better and better.
@arbrix2503
@arbrix2503 2 жыл бұрын
what are the benefits of federation, would'nt that just increase the number of request and delay the loading of the application?
@KevinGhadyani
@KevinGhadyani 2 жыл бұрын
Module Federation does increase the initial number of requests. This is why HTTP/2 is recommended. But the overall payload size could be less with multiple micro frontends on the page, and your payload-over-time cost is even lower. More beneficial to apps unless you do what I did and federate dependencies.
@kalesmca
@kalesmca 3 жыл бұрын
I have a question. Lets consider we have App1, App2, and Main app. => App1 and App2 is exposes into port 3000 and 3001 => Main-App importing those 2-apps. => If App1 is down what will happen? => how to resolve it. => How to catch this kind of exception when we import in Main-app ? Please help me
@KevinGhadyani
@KevinGhadyani 3 жыл бұрын
That's a great question. I'm actually not sure. My implementation of Module Federation was customized, so I had a way of handling it. Not sure how it's done in the official implementation. I'd ask in the Module Federation Slack group for more information.
@madhuchilipi
@madhuchilipi 3 жыл бұрын
i have a question on app1 and app2(if I have 2 developers who want to develop app1- devloper1 app2- developer2 parallelly how can we manage the code and deployments to production)?
@KevinGhadyani
@KevinGhadyani 3 жыл бұрын
Each developer would work on their apps independently. When pushed to production, there are a few ways this works. 1. Your client pulls the latest version dynamically when someone goes to a route where app2 is used. 2. You have app2 deployed as a node_module and the bundle is published separately. There are many other ways to handle it too. Think of these as separate apps. The configuration from there depends on if you need server-side rendering or not.
@frozen_tortus
@frozen_tortus 8 ай бұрын
wooa what a video!
@Tranquility_00
@Tranquility_00 2 жыл бұрын
Is it possible to manually download the script and manually load it? The download magic is so stupid.
@KevinGhadyani
@KevinGhadyani 2 жыл бұрын
Which script are you referring?
@Tranquility_00
@Tranquility_00 2 жыл бұрын
@@KevinGhadyani Thank you for the reply, i was probably wrong, it is probably possible. At 15:39 for example. As i understand, the plugin under the hood uses fetch to download app2 module using the url seen on the screen. After a bit of watching various videos, i think you can just dont put the url and add the script tag in the html (mannually or by code). That would solve webpack making requests to the server, which you can't control or customize.
@Tranquility_00
@Tranquility_00 2 жыл бұрын
@@KevinGhadyani However there is another problem: In case plugin configuration has many exposed modules in the 'exposes' option, it creates a separate file for each exposed module. This is just bad design and could result in many small network requests. Also, this is against the webpack philosophy, which is to BUNDLE things, not to make many small files.
@KevinGhadyani
@KevinGhadyani 2 жыл бұрын
I see what you're saying. That script is on disk, and yes, you can load it yourself. That's how I used Module Federation because I was dealing with an existing app that had 3-6 separate bundles on the same page which needed to share federated modules.
@KevinGhadyani
@KevinGhadyani 2 жыл бұрын
Webpack has the concept of chunking. I've never released a production app as a single monolithic bundle since 2015. Webpack even complains if you're bundle is too large. With HTTP/2, those small network requests aren't an issue.
Five Module Federation/Micro-Frontend Mistakes
28:09
Jack Herrington
Рет қаралды 50 М.
Павел Черторогов - Революция в микрофронтендах, module federation, Webpack 5
1:12:48
HolyJS — конференция для JavaScript‑разработчиков
Рет қаралды 23 М.
Ful Video ☝🏻☝🏻☝🏻
1:01
Arkeolog
Рет қаралды 14 МЛН
Jaidarman TOP / Жоғары лига-2023 / Жекпе-жек 1-ТУР / 1-топ
1:30:54
Webpack 5 Module Federation - Zack Jackson - CityJS Conf 2020
1:01:43
The INSANE complexity of Redux Selectors w/ Mark Erikson #CodeConversation
15:21
Kevin Ghadyani - JavaScript
Рет қаралды 977
Dynamic Module Federation in Next.js? w/ Zach Jackson #CodeConversation
16:47
Kevin Ghadyani - JavaScript
Рет қаралды 6 М.
Introducing Module Federation in Webpack 5
10:39
Jack Herrington
Рет қаралды 89 М.
Bjarne Stroustrup: C++ | Lex Fridman Podcast #48
1:47:13
Lex Fridman
Рет қаралды 1 МЛН
OAuth 2.0 and OpenID Connect (in plain English)
1:02:17
OktaDev
Рет қаралды 1,8 МЛН
Module Federation with CRA & Webpack 5 by Raj Rajhans
29:44
Transformers (how LLMs work) explained visually | DL5
27:14
3Blue1Brown
Рет қаралды 4,3 МЛН
Ful Video ☝🏻☝🏻☝🏻
1:01
Arkeolog
Рет қаралды 14 МЛН