@bagelink/workspace 1.7.37 → 1.7.41

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -162,14 +162,13 @@ export default defineConfig(({ mode }) => {
162
162
  **Access config at runtime with `useWorkspace()`:**
163
163
 
164
164
  ```typescript
165
- import { useWorkspace } from '@bagelink/workspace'
165
+ import { useWorkspace, getApiUrl } from '@bagelink/workspace'
166
166
 
167
167
  // In your app setup
168
168
  const { proxy, host, mode } = useWorkspace()
169
169
  const auth = initAuth({ baseURL: proxy })
170
170
 
171
171
  // Or get full API URL
172
- import { getApiUrl } from '@bagelink/workspace'
173
172
  const apiUrl = getApiUrl() // 'https://project.bagel.to/api'
174
173
  ```
175
174
 
@@ -581,21 +580,37 @@ const proxy = workspace.createProxy(config)
581
580
  workspace.generateNetlify(config, './netlify.toml')
582
581
  ```
583
582
 
584
- ### `createViteProxy(config)`
583
+ ### Build-Time Functions
584
+
585
+ These are available from `@bagelink/workspace/vite`:
586
+
587
+ #### `createViteProxy(config)`
585
588
 
586
589
  Generate Vite proxy configuration.
587
590
 
588
- ### `writeNetlifyConfig(config, outPath?, additionalConfig?)`
591
+ ```typescript
592
+ import { createViteProxy } from '@bagelink/workspace/vite'
593
+ ```
594
+
595
+ #### `writeNetlifyConfig(config, outPath?, additionalConfig?)`
589
596
 
590
597
  Generate and write netlify.toml file.
591
598
 
592
- ### `setBuildEnvVars(config)`
599
+ ```typescript
600
+ import { writeNetlifyConfig } from '@bagelink/workspace/vite'
601
+ ```
602
+
603
+ #### `setBuildEnvVars(config)`
593
604
 
594
605
  Set environment variables for build process:
595
606
  - `BGL_PROXY_PATH` - Proxy path (e.g., `/api`)
596
607
  - `BGL_API_HOST` - API host URL
597
608
  - `BGL_OPENAPI_URL` - OpenAPI specification URL
598
609
 
610
+ ```typescript
611
+ import { setBuildEnvVars } from '@bagelink/workspace/vite'
612
+ ```
613
+
599
614
  ## License
600
615
 
601
616
  MIT © Bagel Studio