This repository has been archived by the owner on Aug 1, 2024. It is now read-only.
Closure Library v20170521
New Additions
- goog.date.DateTime now has an RFC 3339 string method, toUTCRfc3339.
- Added goog.uri.utils.setParamsFromMap() for updating multiple URI params at once.
- goog.fx.DragListGroup.EventType is strongly-typed.
- goog.fx.DragListGroup.prototype.isDragging()
- Currently, goog.ui.ac.RichRemote evals the first element of the response and uses it as a function to pass the remaining elements. This is dangerous (use of eval) and cumbersome (requires exporting the name of the function used in the response). This change allows specifying a row builder which takes both type and the response.
- Add goog.dom.safe.setScriptContent.
- Add goog.Uri.QueryData.prototype.forEach().
Backwards Incompatible Changes
- Delete goog.debug.logRecordSerializer.unsafeParse.
- Fixed possible XSS in goog.html.SafeStyle caused by goog.html.sanitizer.CssSanitizer.sanitizeInlineStyle[String] being passed a opt_urlRewriter that returns a string instead of a SafeUrl.
- Change proto serializer to produce valid JSON.
- Improved handling of non-int value in Long.fromInt
- Delete goog.json.HybridJsonProcessor.
- The CSS sanitizer will not convert property names to lowercase by default any longer.
- Remove unused deprecated goog.dom.$F alias.
- Drop support for preloaded jsunit test managers.
- Change goog.json.unsafeParse to JSON.parse in goog.net packages
- goog.object.getAllPropertyNames excludes the Function.prototype properties by default.
- goog.net.cookies is now typed as non-nullable and const.
- If you use any of the render* methods on goog.soy.Renderer to render Closure Templates, you must update your Closure Templates compiler to https://github\.com/google/closure-templates/commit/a061cb1f619a4ec75e0a28c52b570b94e217429d or later.
- Make BrowserChannel only accept object literals, not legacy goog.structs.Map.
- goog.debug.deepExpose no longer has the side-effect of adding Uids to objects being exposed, The output also contains the UID of any objects that cause reference loops.
- Use JSON.parse in goog.debug.logRecordSerializer.parse.
Other Changes
- SafeUrl.sanitize() becomes slightly more permissive, allowing & before /?#.
- Non functional annotation cleanup on goog.net.cookies
- Disable calls to getResponse*() methods outsdie of event callbacks by default by setting goog.net.testing.XhrIo.allowUnsafeAccessToXhrIoOutsideCallbacks to false. To maintain old behavior, set goog.net.testing.XhrIo.allowUnsafeAccessToXhrIoOutsideCallbacks to true within a test.
- Add optional callback for each completed test.
- Fixes bug in goog.i18n.NumberFormat that caused small numbers to be formatted incorrectly (with non-printable characters) when a high value for maximum fractional digits was used.
- goog.dom.createDom() / goog.dom.setProperties() now accept Safe* values.
- JsDoc fix.
- Add another check for undefined global property to satisfy IE.
- Delete deprecated closure/caja/string/html/htmlsanitizer. Existing users should migrate to directly using the Caja project or use javascript/closure/html/sanitizer/htmlsanitizer.
- CLDR 31 locale data update.
- Add a goog.require for the interface goog.crypt.BlockCipher from goog.crypt.Cbc
- Allow about:blank in TrustedResourceUrl.format.
- Protect against gadget-based CSP bypasses.
- Fixed sanitization of vendor-prefixed CSS properties in IE8.
- Deprecate goog.json.usnafeParse.
- goog.events.EventType is updated with Service Worker events.
- goog.base is deprecated.