@flareapp/core 2.2.0 → 2.3.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.
Files changed (55) hide show
  1. package/README.md +4 -1
  2. package/dist/index.cjs +1152 -0
  3. package/dist/index.d.cts +544 -0
  4. package/dist/index.d.mts +544 -0
  5. package/dist/index.mjs +1104 -0
  6. package/package.json +4 -1
  7. package/.oxlintrc.json +0 -7
  8. package/.release-it.json +0 -13
  9. package/CHANGELOG.md +0 -16
  10. package/src/Flare.ts +0 -543
  11. package/src/Scope.ts +0 -96
  12. package/src/api/Api.ts +0 -35
  13. package/src/api/index.ts +0 -1
  14. package/src/env/index.ts +0 -14
  15. package/src/index.ts +0 -41
  16. package/src/stacktrace/NullFileReader.ts +0 -28
  17. package/src/stacktrace/createStackTrace.ts +0 -74
  18. package/src/stacktrace/fileReader.ts +0 -96
  19. package/src/stacktrace/index.ts +0 -4
  20. package/src/types.ts +0 -81
  21. package/src/util/assert.ts +0 -9
  22. package/src/util/assertKey.ts +0 -11
  23. package/src/util/convertToError.ts +0 -22
  24. package/src/util/extractCode.ts +0 -11
  25. package/src/util/flatJsonStringify.ts +0 -45
  26. package/src/util/glowsToEvents.ts +0 -16
  27. package/src/util/index.ts +0 -8
  28. package/src/util/now.ts +0 -3
  29. package/src/util/redactUrl.ts +0 -83
  30. package/tests/api.test.ts +0 -95
  31. package/tests/configure.test.ts +0 -16
  32. package/tests/contextCollector.test.ts +0 -37
  33. package/tests/convertToError.test.ts +0 -95
  34. package/tests/createStackTrace.test.ts +0 -54
  35. package/tests/extractCode.test.ts +0 -30
  36. package/tests/fileReader.test.ts +0 -51
  37. package/tests/flatJsonStringify.test.ts +0 -31
  38. package/tests/flush.test.ts +0 -47
  39. package/tests/glows.test.ts +0 -47
  40. package/tests/glowsToEvents.test.ts +0 -41
  41. package/tests/helpers/FakeApi.ts +0 -20
  42. package/tests/helpers/index.ts +0 -1
  43. package/tests/hooks.test.ts +0 -123
  44. package/tests/light.test.ts +0 -25
  45. package/tests/nullFileReader.test.ts +0 -11
  46. package/tests/publicExports.test.ts +0 -17
  47. package/tests/redactUrl.test.ts +0 -151
  48. package/tests/report.test.ts +0 -146
  49. package/tests/sampleRate.test.ts +0 -88
  50. package/tests/scope.test.ts +0 -64
  51. package/tests/setEntryPoint.test.ts +0 -79
  52. package/tests/setFramework.test.ts +0 -48
  53. package/tests/setSdkInfo.test.ts +0 -62
  54. package/tsconfig.json +0 -4
  55. package/vitest.config.ts +0 -17
package/README.md CHANGED
@@ -12,9 +12,12 @@ the official SDKs use.
12
12
 
13
13
  - `Flare` — the core class. Takes three optional injection points: `ScopeProvider`,
14
14
  `ContextCollector`, `FileReader`.
15
+ - `Logger` — structured logging (`flare.logger`). Eight syslog levels, opt-in via
16
+ `enableLogs`; owns the log buffer, batching policy, and OTel envelope. A
17
+ `FlushScheduler` seam is injected per platform.
15
18
  - `Scope`, `GlobalScopeProvider`, `ScopeProvider` — per-call mutable state.
16
19
  - `FileReader`, `NullFileReader` — source-snippet reading abstraction.
17
- - `Api` — the HTTP client used to send reports.
20
+ - `Api` — the HTTP client used to send reports and logs.
18
21
  - Types: `Config`, `Report`, `Attributes`, `Glow`, `StackFrame`, etc.
19
22
  - Util: `redactUrlQuery`, `resolveDenylist`, `convertToError`, `DEFAULT_URL_DENYLIST`.
20
23