@launchdarkly/observability 0.4.12 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @launchdarkly/observability
|
|
2
2
|
|
|
3
|
+
## [0.5.0](https://github.com/launchdarkly/observability-sdk/compare/observability-0.4.11...observability-0.5.0) (2025-12-23)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* publish umd for broser environments ([#334](https://github.com/launchdarkly/observability-sdk/issues/334)) ([3e90673](https://github.com/launchdarkly/observability-sdk/commit/3e90673e42335aeeef78cc807a07dfa21da19291))
|
|
9
|
+
|
|
3
10
|
## [0.4.11](https://github.com/launchdarkly/observability-sdk/compare/observability-0.4.10...observability-0.4.11) (2025-12-18)
|
|
4
11
|
|
|
5
12
|
|
package/dist/index.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(nt,me){typeof exports=="object"&&typeof module<"u"?me(exports):typeof define=="function"&&define.amd?define(["exports"],me):(nt=typeof globalThis<"u"?globalThis:nt||self,me(nt.
|
|
1
|
+
(function(nt,me){typeof exports=="object"&&typeof module<"u"?me(exports):typeof define=="function"&&define.amd?define(["exports"],me):(nt=typeof globalThis<"u"?globalThis:nt||self,me(nt.Observability={}))})(this,function(nt){"use strict";var me=Object.defineProperty,_c=(t,e,r)=>e in t?me(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,vt=(t,e,r)=>_c(t,typeof e!="symbol"?e+"":e,r),gc=(t,e,r)=>new Promise((n,i)=>{var o=c=>{try{u(r.next(c))}catch(s){i(s)}},a=c=>{try{u(r.throw(c))}catch(s){i(s)}},u=c=>c.done?n(c.value):Promise.resolve(c.value).then(o,a);u((r=r.apply(t,e)).next())});const po=Object.create(null),Tt=(t,e,...r)=>{const n=`[@launchdarkly plugins]: (${t}): `;console[e].apply(console,[n,...r]),Ec(n,...r)},bt=(t,e,r,...n)=>{po[`${t}-${e}`]||(po[`${t}-${e}`]=!0,Tt(t,r,...n))},Ec=(t,...e)=>gc(void 0,null,function*(){try{const{LDObserve:r}=yield Promise.resolve().then(()=>$p);r.recordLog(`${t}${e}`,"warn")}catch{}});class Tc{constructor(e,r){vt(this,"debug"),vt(this,"name"),this.debug=e,this.name=r}log(...e){if(this.debug){let r=`[${Date.now()}]`;this.name&&(r+=` - ${this.name}`),console.log.apply(console,[r,...e])}}warn(...e){let r=`[${Date.now()}]`;this.name&&(r+=` - ${this.name}`),console.warn.apply(console,[r,...e])}}let fo=class{constructor(){vt(this,"_sdk"),vt(this,"_isLoaded",!1),vt(this,"_callBuffer",[]),vt(this,"_capacity",1e5),vt(this,"_droppedEvents",0),vt(this,"_exceededCapacity",!1),vt(this,"_logger",new Tc)}_bufferCall(e,r){if(this._isLoaded)try{return this._sdk[e](...r)}catch(n){Tt(`Error executing buffered call to ${e}:`,"error",n)}else{this._enqueue({method:e,args:r});return}}_enqueue(e){this._callBuffer.length<this._capacity?(this._callBuffer.push(e),this._exceededCapacity=!1):(this._exceededCapacity||(this._exceededCapacity=!0,Tt("Exceeded event queue capacity. Increase capacity to avoid dropping events.","warn")),this._droppedEvents+=1)}load(e){this._sdk=e,this._isLoaded=!0;for(const{method:r,args:n}of this._callBuffer)try{this._sdk[r](...n)}catch(i){Tt(`Error executing buffered call to ${r}:`,"error",i)}this._callBuffer=[]}};var bc=Object.defineProperty,Oc=Object.defineProperties,Sc=Object.getOwnPropertyDescriptors,Ze=Object.getOwnPropertySymbols,ho=Object.prototype.hasOwnProperty,vo=Object.prototype.propertyIsEnumerable,en=(t,e,r)=>e in t?bc(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,C=(t,e)=>{for(var r in e||(e={}))ho.call(e,r)&&en(t,r,e[r]);if(Ze)for(var r of Ze(e))vo.call(e,r)&&en(t,r,e[r]);return t},tr=(t,e)=>Oc(t,Sc(e)),_e=(t,e)=>{var r={};for(var n in t)ho.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(t!=null&&Ze)for(var n of Ze(t))e.indexOf(n)<0&&vo.call(t,n)&&(r[n]=t[n]);return r},ge=(t,e,r)=>en(t,typeof e!="symbol"?e+"":e,r),Yt=(t,e,r)=>new Promise((n,i)=>{var o=c=>{try{u(r.next(c))}catch(s){i(s)}},a=c=>{try{u(r.throw(c))}catch(s){i(s)}},u=c=>c.done?n(c.value):Promise.resolve(c.value).then(o,a);u((r=r.apply(t,e)).next())});function wc(t,e){for(var r=0;r<e.length;r++){const n=e[r];if(typeof n!="string"&&!Array.isArray(n)){for(const i in n)if(i!=="default"&&!(i in t)){const o=Object.getOwnPropertyDescriptor(n,i);o&&Object.defineProperty(t,i,o.get?o:{enumerable:!0,get:()=>n[i]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}function er(t,e){throw new Error(e)}function Ac(t){return typeof t=="object"&&t!==null}function Lc(t,e){throw new Error("Unexpected invariant triggered.")}const Rc=/\r\n|[\n\r]/g;function rn(t,e){let r=0,n=1;for(const i of t.body.matchAll(Rc)){if(typeof i.index=="number"||Lc(),i.index>=e)break;r=i.index+i[0].length,n+=1}return{line:n,column:e+1-r}}function Nc(t){return yo(t.source,rn(t.source,t.start))}function yo(t,e){const r=t.locationOffset.column-1,n="".padStart(r)+t.body,i=e.line-1,o=t.locationOffset.line-1,a=e.line+o,u=e.line===1?r:0,c=e.column+u,s=`${t.name}:${a}:${c}
|
|
2
2
|
`,l=n.split(/\r\n|[\n\r]/g),p=l[i];if(p.length>120){const f=Math.floor(c/80),y=c%80,v=[];for(let m=0;m<p.length;m+=80)v.push(p.slice(m,m+80));return s+mo([[`${a} |`,v[0]],...v.slice(1,f+1).map(m=>["|",m]),["|","^".padStart(y)],["|",v[f+1]]])}return s+mo([[`${a-1} |`,l[i-1]],[`${a} |`,p],["|","^".padStart(c)],[`${a+1} |`,l[i+1]]])}function mo(t){const e=t.filter(([n,i])=>i!==void 0),r=Math.max(...e.map(([n])=>n.length));return e.map(([n,i])=>n.padStart(r)+(i?" "+i:"")).join(`
|
|
3
3
|
`)}function Cc(t){const e=t[0];return e==null||"kind"in e||"length"in e?{nodes:e,source:t[1],positions:t[2],path:t[3],originalError:t[4],extensions:t[5]}:e}let xc=class mc extends Error{constructor(e,...r){var n,i,o;const{nodes:a,source:u,positions:c,path:s,originalError:l,extensions:p}=Cc(r);super(e),this.name="GraphQLError",this.path=s??void 0,this.originalError=l??void 0,this.nodes=_o(Array.isArray(a)?a:a?[a]:void 0);const f=_o((n=this.nodes)===null||n===void 0?void 0:n.map(v=>v.loc).filter(v=>v!=null));this.source=u??(f==null||(i=f[0])===null||i===void 0?void 0:i.source),this.positions=c??f?.map(v=>v.start),this.locations=c&&u?c.map(v=>rn(u,v)):f?.map(v=>rn(v.source,v.start));const y=Ac(l?.extensions)?l?.extensions:void 0;this.extensions=(o=p??y)!==null&&o!==void 0?o:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),l!=null&&l.stack?Object.defineProperty(this,"stack",{value:l.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,mc):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let e=this.message;if(this.nodes)for(const r of this.nodes)r.loc&&(e+=`
|
|
4
4
|
|