A local-first personal finance app
[AI] fix(api): prevent navigator crash when loading @actual-app/api in Node.js (#8037)
Kyle Slattery24fd6239d71d
diff --git a/packages/loot-core/src/shared/months.ts b/packages/loot-core/src/shared/months.tsindex c4eccfae30..247262d207 100644--- a/packages/loot-core/src/shared/months.ts+++ b/packages/loot-core/src/shared/months.ts@@ -3,10 +3,9 @@ import * as d from 'date-fns';import type { Locale } from 'date-fns';import memoizeOne from 'memoize-one';+import * as Platform from '#shared/platform';import type { SyncedPrefs } from '#types/prefs';-import * as Platform from './platform';-type DateLike = string | Date;type Day = 0 | 1 | 2 | 3 | 4 | 5 | 6;diff --git a/upcoming-release-notes/8037.md b/upcoming-release-notes/8037.mdnew file mode 100644index 0000000000..bd30eb1a70--- /dev/null+++ b/upcoming-release-notes/8037.md@@ -0,0 +1,6 @@+---+category: Bugfixes+authors: [kyleslattery]+---++Importing `@actual-app/api` in a Node.js environment was causing a ReferenceError, due to how the build handles relative paths.