Bug 1419370 - remove immutablejs from netmonitor. r=honza
authormsecret <msegreto@miceover.com>
Fri, 05 Jan 2018 10:30:03 -0800
changeset 398529 6984e56259d8
parent 398528 1adb2c87c080
child 398530 8e14dd890c5e
push id98766
push userncsoregi@mozilla.com
push dateWed, 10 Jan 2018 10:29:28 +0000
treeherdermozilla-inbound@6984e56259d8 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewershonza
bugs1419370
milestone59.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1419370 - remove immutablejs from netmonitor. r=honza Remove the use of `Immutable.is` in Toolbar, this method should map directly to `Object.is`. The props being passed to `is` were already plain JS objects from what I understand. Yarn was used to remove the Immutable JS package and webpack was configured to not include webpack from shared assets. *** Removed Immutable reference in yarn.lock *** Generated yarn.lock file By running `yarn install`. *** Remove debugging statements
devtools/client/netmonitor/package.json
devtools/client/netmonitor/src/components/Toolbar.js
devtools/client/netmonitor/webpack.config.js
devtools/client/netmonitor/yarn.lock
--- a/devtools/client/netmonitor/package.json
+++ b/devtools/client/netmonitor/package.json
@@ -7,17 +7,16 @@
   "description": "Network monitor in developer tools",
   "dependencies": {
     "codemirror": "^5.24.2",
     "devtools-config": "=0.0.12",
     "devtools-contextmenu": "=0.0.3",
     "devtools-launchpad": "=0.0.103",
     "devtools-modules": "=0.0.32",
     "devtools-source-editor": "=0.0.3",
-    "immutable": "^3.8.1",
     "jszip": "^3.1.3",
     "react": "=15.6.1",
     "react-dom": "=15.6.1",
     "react-redux": "=5.0.3",
     "redux": "^3.6.0",
     "reselect": "^3.0.1"
   },
   "devDependencies": {
--- a/devtools/client/netmonitor/src/components/Toolbar.js
+++ b/devtools/client/netmonitor/src/components/Toolbar.js
@@ -4,17 +4,16 @@
 
 "use strict";
 
 const Services = require("Services");
 const { Component, createFactory } = require("devtools/client/shared/vendor/react");
 const dom = require("devtools/client/shared/vendor/react-dom-factories");
 const PropTypes = require("devtools/client/shared/vendor/react-prop-types");
 const { connect } = require("devtools/client/shared/vendor/react-redux");
-const I = require("devtools/client/shared/vendor/immutable");
 
 const Actions = require("../actions/index");
 const { FILTER_SEARCH_DELAY, FILTER_TAGS } = require("../constants");
 const {
   getRecordingState,
   getTypeFilteredRequests,
   isNetworkDetailsToggleButtonDisabled,
 } = require("../selectors/index");
@@ -93,17 +92,17 @@ class Toolbar extends Component {
   }
 
   shouldComponentUpdate(nextProps) {
     return this.props.networkDetailsOpen !== nextProps.networkDetailsOpen
     || this.props.networkDetailsToggleDisabled !== nextProps.networkDetailsToggleDisabled
     || this.props.persistentLogsEnabled !== nextProps.persistentLogsEnabled
     || this.props.browserCacheDisabled !== nextProps.browserCacheDisabled
     || this.props.recording !== nextProps.recording
-    || !I.is(this.props.requestFilterTypes, nextProps.requestFilterTypes)
+    || !Object.is(this.props.requestFilterTypes, nextProps.requestFilterTypes)
 
     // Filtered requests are useful only when searchbox is focused
     || !!(this.refs.searchbox && this.refs.searchbox.focused);
   }
 
   componentWillUnmount() {
     Services.prefs.removeObserver(DEVTOOLS_ENABLE_PERSISTENT_LOG_PREF,
                                   this.updatePersistentLogsEnabled);
--- a/devtools/client/netmonitor/webpack.config.js
+++ b/devtools/client/netmonitor/webpack.config.js
@@ -70,17 +70,16 @@ let webpackConfig = {
     alias: {
       "Services": "devtools-modules/src/Services",
       "react": path.join(__dirname, "node_modules/react"),
 
       "devtools/client/framework/devtools": path.join(__dirname, "../../client/shared/webpack/shims/framework-devtools-shim"),
       "devtools/client/framework/menu": "devtools-modules/src/menu",
       "devtools/client/netmonitor/src/utils/menu": "devtools-contextmenu",
 
-      "devtools/client/shared/vendor/immutable": "immutable",
       "devtools/client/shared/vendor/react": "react",
       "devtools/client/shared/vendor/react-dom": "react-dom",
       "devtools/client/shared/vendor/react-redux": "react-redux",
       "devtools/client/shared/vendor/redux": "redux",
       "devtools/client/shared/vendor/reselect": "reselect",
       "devtools/client/shared/vendor/jszip": "jszip",
 
       "devtools/client/sourceeditor/editor": "devtools-source-editor/src/source-editor",
--- a/devtools/client/netmonitor/yarn.lock
+++ b/devtools/client/netmonitor/yarn.lock
@@ -2410,19 +2410,19 @@ icss-replace-symbols@^1.0.2:
 ieee754@^1.1.4:
   version "1.1.8"
   resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.1.8.tgz#be33d40ac10ef1926701f6f08a2d86fbfd1ad3e4"
 
 immediate@~3.0.5:
   version "3.0.6"
   resolved "https://registry.yarnpkg.com/immediate/-/immediate-3.0.6.tgz#9db1dbd0faf8de6fbe0f5dd5e56bb606280de69b"
 
-immutable@^3.7.6, immutable@^3.8.1:
-  version "3.8.1"
-  resolved "https://registry.yarnpkg.com/immutable/-/immutable-3.8.1.tgz#200807f11ab0f72710ea485542de088075f68cd2"
+immutable@^3.7.6:
+  version "3.8.2"
+  resolved "https://registry.yarnpkg.com/immutable/-/immutable-3.8.2.tgz#c2439951455bb39913daf281376f1530e104adf3"
 
 indexes-of@^1.0.1:
   version "1.0.1"
   resolved "https://registry.yarnpkg.com/indexes-of/-/indexes-of-1.0.1.tgz#f30f716c8e2bd346c7b67d3df3915566a7c05607"
 
 indexof@0.0.1:
   version "0.0.1"
   resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d"