There seem to be an issue when building a production build, specifically using Vite.
Documents.RESOURCEPATH returns undefined. Since this is a getter defined in SearchOnlyDocuments and Documents gets it by inheritance, I figured we could probably just remove the reference to Documents.
I think the issue is caused by the circular dependency between SearchOnlyDocuments and Documents and gets a bit muffled at build/shrinking time, so this looks like a proper fix.
I can confirmed it resolved our issue on our side.
Change Summary
There seem to be an issue when building a production build, specifically using Vite.
Documents.RESOURCEPATH
returns undefined. Since this is a getter defined inSearchOnlyDocuments
andDocuments
gets it by inheritance, I figured we could probably just remove the reference to Documents.I think the issue is caused by the circular dependency between
SearchOnlyDocuments
andDocuments
and gets a bit muffled at build/shrinking time, so this looks like a proper fix.I can confirmed it resolved our issue on our side.
See associated Slack thread
PR Checklist