ok I have a DAO (database access object) that is to be server side and I want to call from the loader and I have gone through so many stages of wtf.
i'm importing this dao on the route where I need to load stuff, and I call its methods on the loader function, and that seems to be fine, but for some reason I get errors on the client referencing server stuff - latest being Buffer not being a thing and the stack going down to drizzle - but why is drizzlestuff also happening on the client side? I'm only using the dao in the loader and I can see that vite logs (on the server side) when the loader is invoked and retrieves the data