Chrome 46 Beta: Flexible animations and improved loading performance
Wednesday, September 2, 2015
Animating objects along author specified paths
Previously, animating objects along an author-specified path required complex javascript code that could block important events like rendering and input. Developers can now animate any graphical object along an arbitrary path declaratively as a CSS property, allowing simpler code that doesn’t block rendering or input.
Complex animations using CSS
Optimized image loading and service worker instrumentation
Tools like srcset allow developers to serve an optimized image variant in a responsive way, but it can be cumbersome and inefficient to use in practice. Developers can now negotiate with the server to download the best image variant for a device using straightforward HTTP request headers. These headers communicate DPR, Viewport-Width, and the intended display width of the resource being fetched to the server.
In addition to improving image loading, developers can now instrument service workers to gather detailed fetch and script timing. Developers can also measure the startup time of service workers more accurately.
Other updates in this release
- As part of Chrome’s ongoing efforts to ship features from the ES2015 specification, Chrome now supports the spread operator and new.target.
- To prevent user annoyance and conserve power, Chrome will now defer playback of autoplay videos in background tabs until the first time the tab is foregrounded.
- Developers can now disable Chrome’s default scroll restoration behavior on history navigation when it interferes with the app’s user experience.
- Sites launched from the home screen can now modify the default color of Chrome’s UI by specifying a theme color in their web manifest instead of a meta tag.
- Sites that have been added to the homescreen can now set a background color to show while resources load.
- Developers can now specify a URI for Chrome to report HTTP Public Key Pinning violations to, making man-in-the-middle attacks easier to find.
- Events generated by user action can be differentiated from events generated by script using Event.isTrusted(), allowing developers to protect against fake clicks.
- Developers can now use CSS.escape(), eliminating the need for complicated string escape code while handling user generated identifiers.
- Modal dialogs are now blocked by default in sandboxed iframes, preventing embedded content from abusing APIs like alert.
- As part of our continuing policy to remove powerful APIs on insecure origins, the Cache API is now restricted to HTTPS.
- Cache.addAll() is now supported, removing the need for polyfills enabling bulk interactions with the cache.
- DOMExceptions can now be constructed from scripts, making polyfills easier to build for specs that require exceptions.
- Timer-based polling is no longer necessary to use WebRTC DataChannels, making them more efficient and convenient.
Posted by Eric Willigers, Software Engineer and Animations Acrobat