What is the main benefit of using bundle preloading in a Firebase web app?
Think about how preloading affects when code is downloaded.
Bundle preloading helps by loading important code early, so the app feels faster when users navigate.
Which Firebase Hosting configuration snippet correctly preloads a JavaScript bundle named main.js?
Look for the correct HTTP header and relation type for preloading scripts.
The Link header with rel=preload and as=script tells browsers to preload the JavaScript file.
You have a Firebase app with multiple code bundles. Which strategy best balances fast initial load and efficient bandwidth when using bundle preloading?
Consider user experience and network usage trade-offs.
Preloading only the main bundle ensures quick startup without wasting bandwidth on unused code.
What is a potential security risk when improperly configuring bundle preloading in Firebase Hosting?
Think about who can access preloaded resources.
If sensitive bundles are preloaded without access control, unauthorized users might download them.
When you add a Link header with rel=preload for a bundle in Firebase Hosting, how does it affect the browser cache behavior for that bundle?
Consider how preloading interacts with browser caching mechanisms.
Preloading causes the browser to fetch and store the bundle early, so it can be reused without delay later.