@absolutejs/absolute 0.19.0-beta.1126 → 0.19.0-beta.1127
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 +20 -0
- package/dist/angular/browser.js +3 -3
- package/dist/angular/browser.js.map +3 -3
- package/dist/angular/components/core/streamingSlotRegistrar.js +1 -1
- package/dist/angular/components/core/streamingSlotRegistry.js +2 -2
- package/dist/build.js +3 -3
- package/dist/build.js.map +3 -3
- package/dist/cli/index.js +150 -85
- package/dist/index.js +4 -4
- package/dist/index.js.map +4 -4
- package/dist/src/cli/scripts/start.d.ts +6 -1
- package/dist/src/utils/imageProcessing.d.ts +1 -1
- package/dist/types/image.d.ts +2 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -105,6 +105,26 @@ export const server = new Elysia()
|
|
|
105
105
|
2. Route handlers (`handleReactPageRequest`, `handleSveltePageRequest`, …) stream HTML and inject scripts/assets based on that manifest.
|
|
106
106
|
3. The static plugin serves all compiled files from `/build`.
|
|
107
107
|
|
|
108
|
+
### Immutable production images
|
|
109
|
+
|
|
110
|
+
Build production assets and the server bundle while constructing the image,
|
|
111
|
+
then launch that prepared output without writing to it at runtime:
|
|
112
|
+
|
|
113
|
+
```bash
|
|
114
|
+
absolute prepare src/server.ts --outdir build
|
|
115
|
+
absolute start src/server.ts --outdir build --prebuilt
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
If image optimization is enabled in a read-only container, configure its
|
|
119
|
+
runtime cache on a bounded writable filesystem such as a `tmpfs`:
|
|
120
|
+
|
|
121
|
+
```ts
|
|
122
|
+
export default defineConfig({
|
|
123
|
+
buildDirectory: 'build',
|
|
124
|
+
images: { cacheDirectory: '/tmp/absolutejs-image-cache' }
|
|
125
|
+
});
|
|
126
|
+
```
|
|
127
|
+
|
|
108
128
|
---
|
|
109
129
|
|
|
110
130
|
## Plugin System
|
package/dist/angular/browser.js
CHANGED
|
@@ -9154,8 +9154,8 @@ var DEFAULT_DEVICE_SIZES, DEFAULT_IMAGE_SIZES, DEFAULT_QUALITY, OPTIMIZATION_END
|
|
|
9154
9154
|
const device = config?.deviceSizes ?? DEFAULT_DEVICE_SIZES;
|
|
9155
9155
|
const image = config?.imageSizes ?? DEFAULT_IMAGE_SIZES;
|
|
9156
9156
|
return [...device, ...image].sort((left, right) => left - right);
|
|
9157
|
-
}, getCacheDir = (buildDir) => {
|
|
9158
|
-
const dir = join(buildDir, ".cache", "images");
|
|
9157
|
+
}, getCacheDir = (buildDir, cacheDirectory) => {
|
|
9158
|
+
const dir = cacheDirectory ? resolve(cacheDirectory) : join(buildDir, ".cache", "images");
|
|
9159
9159
|
if (!existsSync(dir))
|
|
9160
9160
|
mkdirSync(dir, { recursive: true });
|
|
9161
9161
|
return dir;
|
|
@@ -10361,5 +10361,5 @@ export {
|
|
|
10361
10361
|
ABSOLUTE_HTTP_TRANSFER_CACHE_SKIP_HEADER
|
|
10362
10362
|
};
|
|
10363
10363
|
|
|
10364
|
-
//# debugId=
|
|
10364
|
+
//# debugId=7F459B45B76DA26564756E2164756E21
|
|
10365
10365
|
//# sourceMappingURL=browser.js.map
|