Skip to content

Commit f3d85e2

Browse files
committed
rn initiatorTypes
1 parent 1d77b6c commit f3d85e2

File tree

1 file changed

+4
-4
lines changed
  • packages/rrweb/src/plugins/network/record

1 file changed

+4
-4
lines changed

packages/rrweb/src/plugins/network/record/index.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ export type InitiatorType =
2626
| 'xmlhttprequest';
2727

2828
type NetworkRecordOptions = {
29-
initiatorType?: InitiatorType[];
29+
initiatorTypes?: InitiatorType[];
3030
ignoreRequestFn?: (data: NetworkRequest) => boolean;
3131
recordHeaders?:
3232
| boolean
@@ -46,7 +46,7 @@ type NetworkRecordOptions = {
4646
};
4747

4848
const defaultNetworkOptions: NetworkRecordOptions = {
49-
initiatorType: [
49+
initiatorTypes: [
5050
'audio',
5151
'beacon',
5252
'body',
@@ -151,7 +151,7 @@ function initXhrObserver(
151151
win: IWindow,
152152
options: Required<NetworkRecordOptions>,
153153
): listenerHandler {
154-
if (!options.initiatorType.includes('xmlhttprequest')) {
154+
if (!options.initiatorTypes.includes('xmlhttprequest')) {
155155
return () => {
156156
//
157157
};
@@ -166,7 +166,7 @@ function initFetchObserver(
166166
win: IWindow,
167167
options: Required<NetworkRecordOptions>,
168168
): listenerHandler {
169-
if (!options.initiatorType.includes('fetch')) {
169+
if (!options.initiatorTypes.includes('fetch')) {
170170
return () => {
171171
//
172172
};

0 commit comments

Comments
 (0)