brainy/cloud-wrapper/src
David Snelling 0cf4a0eee8 **refactor: improve imports, route handling, and environment detection**
### Changes:
- Added explicit `.js` extensions to imports in `cloud-wrapper/src/index.ts` for Node.js compatibility.
- Refactored `setupRoutes` usage by introducing an `apiRouter` variable for clarity and consistency in middleware.
- Simplified environment detection in `src/unified.ts` by delegating it to build-time logic:
  - Removed inline environment detection (`isBrowser`, `isNode`, `isServerless`).
  - Updated `environment` export with build-generated properties.

### Purpose:
Enhanced compatibility with Node.js module resolution, improved code clarity in route handling, and streamlined environment detection by consolidating it into the build process. These changes reduce redundancy, improve maintainability, and align with modern JavaScript practices.
2025-06-19 16:03:31 -07:00
..
services **feat: enhance BrainyData storage configuration with support for custom S3 endpoints and extended types** 2025-06-19 15:12:51 -07:00
index.ts **refactor: improve imports, route handling, and environment detection** 2025-06-19 16:03:31 -07:00
routes.ts **refactor: add async error handler utility and standardize route handlers** 2025-06-19 16:03:04 -07:00
websocket.ts feat: add WebSocket API, REST API routes, and server setup for Brainy 2025-06-06 09:09:07 -07:00