From f4b3f1daa3ac559eee2a4c9d56509f319f1ec273 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dawid=20Ma=C5=82ecki?= Date: Mon, 20 Jan 2025 05:38:58 -0800 Subject: [PATCH] Change InspectorAgent import syntax in NetworkAgent (#48729) Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/48729 Changelog: [Internal] - Changed InspectorAgent import syntax in NetworkAgent Reviewed By: rshest Differential Revision: D68270365 fbshipit-source-id: d8cea061d82f6fd4c36830820ef8fef2115f1d43 --- packages/react-native/Libraries/JSInspector/NetworkAgent.js | 3 ++- .../Libraries/__tests__/__snapshots__/public-api-test.js.snap | 3 +-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/react-native/Libraries/JSInspector/NetworkAgent.js b/packages/react-native/Libraries/JSInspector/NetworkAgent.js index 7a599d64aac..495b5c9f625 100644 --- a/packages/react-native/Libraries/JSInspector/NetworkAgent.js +++ b/packages/react-native/Libraries/JSInspector/NetworkAgent.js @@ -12,8 +12,9 @@ import type EventSender from './InspectorAgent'; +import InspectorAgent from './InspectorAgent'; + const XMLHttpRequest = require('../Network/XMLHttpRequest'); -const InspectorAgent = require('./InspectorAgent'); const JSInspector = require('./JSInspector'); type RequestId = string; diff --git a/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap b/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap index ff5b2b5853c..30c48992539 100644 --- a/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap +++ b/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap @@ -5570,8 +5570,7 @@ declare module.exports: JSInspector; `; exports[`public API should not change unintentionally Libraries/JSInspector/NetworkAgent.js 1`] = ` -"declare const InspectorAgent: $FlowFixMe; -type RequestId = string; +"type RequestId = string; type Headers = { [string]: string }; declare class Interceptor { _agent: NetworkAgent;