diff --git a/plugins/web/opentelemetry-instrumentation-document-load/src/instrumentation.ts b/plugins/web/opentelemetry-instrumentation-document-load/src/instrumentation.ts index 27712e63cc..95399d6111 100644 --- a/plugins/web/opentelemetry-instrumentation-document-load/src/instrumentation.ts +++ b/plugins/web/opentelemetry-instrumentation-document-load/src/instrumentation.ts @@ -90,7 +90,7 @@ export class DocumentLoadInstrumentation extends InstrumentationBase { * Collects information about performance and creates appropriate spans */ private _collectPerformance() { - const metaElement = [...document.getElementsByTagName('meta')].find( + const metaElement = Array.from(document.getElementsByTagName('meta')).find( e => e.getAttribute('name') === TRACE_PARENT_HEADER ); const entries = getPerformanceNavigationEntries(); diff --git a/tsconfig.base.esm.json b/tsconfig.base.esm.json index 5dbd1afb11..e65651a426 100644 --- a/tsconfig.base.esm.json +++ b/tsconfig.base.esm.json @@ -1,5 +1,5 @@ { - "extends": "./tsconfig.base.json", + "extends": "./tsconfig.es5.json", "compilerOptions": { "module": "ES6", "moduleResolution": "node" diff --git a/tsconfig.es5.json b/tsconfig.es5.json new file mode 100644 index 0000000000..3c83c51a2b --- /dev/null +++ b/tsconfig.es5.json @@ -0,0 +1,6 @@ +{ + "extends": "./tsconfig.base.json", + "compilerOptions": { + "target": "es5" + } +}