Google heeft versie 47 van zijn webbrowser Chrome uitgebracht. Google Chrome is beschikbaar voor Windows, Linux en OS X. Er zijn ook versies voor Android en iOS, maar die volgen een iets ander releaseschema. In versie 47 zijn onder meer animaties toegevoegd aan web apps, zodat iets te zien val wanneer ze op de achtergrond laden, is er ondersteuning voor cooperative multitasking en kunnen notificaties nu gesloten worden. Ook zijn er natuurlijk weer de nodige bugfixes doorgevoerd en beveiligingsproblemen verholpen. De belangrijkste verbeteringen zijn hieronder nog eens voor je op een rijtje gezet.
Splash screens on Android
Mobile devices are typically less powerful than desktops, meaning apps can take a few seconds to load. Splash screens allow apps to show something meaningful to users as the app loads, improving perceived performance. The new version of Chrome for Android brings splash screens to web apps when a site is launched from the Android home screen. The splash screen is shown immediately, even while Chrome itself is loading. Developers can customize the splash screen by setting a name, icon, background color, and notification bar color in the web app manifest. The splash screen disappears once the web app begins to draw to the screen, providing a more polished loading experience.
Cooperative multitasking with requestIdleCallback()
To achieve a screen refresh rate of 60 frames per second, developers must guess when performance-critical tasks like rendering will finish and use timers to schedule around them. Unfortunately, developers can’t guarantee that low priority work won’t hurt performance because events like scrolling cannot be predicted. Now developers can explicitly set work to run during idle time using requestIdleCallback(). Functions registered with requestIdleCallback() are given a deadline and can return before that limit is reached to avoid jank. The function can register for another requestIdleCallback() to continue work during the next idle period.
Auto dismissing notifications
Push notifications have been enabled by service workers since Chrome 42. Sites such as social media or email can generate a large number of push notifications that take up screen space and aren’t particularly relevant unless viewed soon after posting. The new version of Chrome now allows developers to configure automatic dismissal of desktop notifications, improving the experience for these kinds of notifications. Sites can set NotificationOptions.requireInteraction to indicate the notification should remain onscreen until the user dismisses it.
Other updates in this release
- Array.prototype.includes() simplifies the syntax for checking array membership.
- The rest parameters syntax allows functions with an indefinite number of arguments to be called using arrays.
- Cache.matchAll() simplifies bulk searching of the cache and removes the need for polyfills.
- RequestInit.referrer allows requests captured by service workers to match the original referrer.
- The new Navigator.MediaDevices interface allows developers to enumerate connected media devices such as audio output.
- Updated values for request properties in navigation FetchEvents offer improved spec compliance.
- MouseEvent.getModifierState() makes input processing more powerful and consistent across MouseEvent and KeyboardEvent.
- Developers can now more accurately detect input device capabilities using UIEvent.sourceCapabilities and InputDeviceCapabilities.firesTouchEvents.
- Several SVG methods have been removed, including pixel conversions and hasExtension() methods on several elements.
- Prefixed encrypted media extensions are now disabled in favor of unprefixed EMEs, which have more capabilities and conform to the spec.
- Chrome no longer highlights the gaps between content when painting selections.
- The notification center has been removed from Windows, Mac, and Linux to keep Chrome simpler.