mirror of
https://github.com/appy-one/acebase.git
synced 2026-05-25 06:02:14 -06:00
[GH-ISSUE #206] Getting feature not supported error when attempting to run in Electron app #97
Labels
No labels
IndexedDB
browser
bug
dependencies
documentation
duplicate
enhancement
feature request
indexes
indexes
invalid
pull-request
query
question
transaction logging
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/acebase#97
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @csuwildcat on GitHub (Feb 16, 2023).
Original GitHub issue: https://github.com/appy-one/acebase/issues/206
I can only get Acebase to run in Electron if I use the
AceBase.WithIndexedDBstorage option, even though Electron has full Node.js access to the file system. Is there perhaps some feature detection code that is viewing Electron only as a browser, because it contains access to both IDB and the file system?@appy-one commented on GitHub (Feb 16, 2023):
Sounds like you are using AceBase on the UI (
BrowserWindow) thread instead of in the main (Node.js) process. Move the AceBase code into your main process (or preload.js) to store data to your local file system.@csuwildcat commented on GitHub (Feb 16, 2023):
@appy-one yeah, got it going in that env, but it led to a follow-up question: do you know of any existing uses of AceBase in Electron that show the best way to leverage the storage residing in the main Node process from the render process? I suppose IPC messaging?
@appy-one commented on GitHub (Feb 18, 2023):
I don't have any experience with this myself, but I reckon Electron's IPC is indeed the easiest way to pass data back and forth
@appy-one commented on GitHub (Feb 18, 2023):
Maybe even better, this is what I would do: start a local acebase-server instance in your main process and use an acebase-client in your UI thread to connect to it!
@csuwildcat commented on GitHub (Feb 18, 2023):
Thank you for the suggestion, I think the server route is likely to be the easiest, so I'll try that!