@worktif/runtime 0.3.0-edge.37 → 0.3.0-edge.38

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.
@@ -13,4 +13,3 @@
13
13
  */
14
14
  export * from './pipelines';
15
15
  export * from './types';
16
- export * from './pureweb';
@@ -1,62 +0,0 @@
1
- import type { RuntimeWebConfig } from './types';
2
- /**
3
- * Error thrown when configuration validation fails.
4
- */
5
- export declare class ConfigValidationError extends Error {
6
- /** Array of validation error messages */
7
- readonly errors: string[];
8
- constructor(errors: string[]);
9
- }
10
- /**
11
- * Error thrown when environment detection fails.
12
- */
13
- export declare class EnvironmentDetectionError extends Error {
14
- constructor(message: string);
15
- }
16
- /**
17
- * Unified entry point for Runtime Web Core.
18
- *
19
- * This function provides a single API that works across all execution contexts:
20
- * - **Browser**: Hydrates React application with client-side routing
21
- * - **Lambda**: Executes server-side rendering and business logic with DI
22
- * - **CDK**: Synthesizes CloudFormation infrastructure templates
23
- *
24
- * The function automatically detects the runtime environment and routes
25
- * execution to the appropriate pipeline without user intervention.
26
- *
27
- * **Note**: For Lambda and CDK contexts, use the server-side entry point
28
- * from `@core/runtime-web` instead. This browser-compatible version
29
- * only supports browser hydration.
30
- *
31
- * @param config - Unified configuration for all contexts
32
- * @returns Promise that resolves when execution completes
33
- * @throws ConfigValidationError if configuration is invalid
34
- * @throws EnvironmentDetectionError if environment cannot be detected
35
- * @throws Error if execution fails
36
- *
37
- * @example
38
- * ```typescript
39
- * import { runtime } from '@worktif/runtime/runtime-web';
40
- * import { RuntimeRouter } from '@worktif/runtime';
41
- *
42
- * runtime({
43
- * app: ({ router }) => <App router={router} />,
44
- * router: new RuntimeRouter({ routes, defaults: {} }),
45
- * serviceName: 'my-app',
46
- * stage: 'dev',
47
- * register: {
48
- * payments: {
49
- * ties: [PaymentsTies],
50
- * lambdas: [chargeHandler, refundHandler]
51
- * }
52
- * },
53
- * infra: {
54
- * env: { account: '123456789012', region: 'us-east-1' },
55
- * stage: 'dev',
56
- * reactEntry: './src/index.tsx',
57
- * apiMode: 'apiGateway'
58
- * }
59
- * });
60
- * ```
61
- */
62
- export declare function pureweb(config: RuntimeWebConfig): void;
@@ -13,4 +13,3 @@
13
13
  */
14
14
  export * from './pipelines';
15
15
  export * from './types';
16
- export * from './pureweb';
@@ -1,62 +0,0 @@
1
- import type { RuntimeWebConfig } from './types';
2
- /**
3
- * Error thrown when configuration validation fails.
4
- */
5
- export declare class ConfigValidationError extends Error {
6
- /** Array of validation error messages */
7
- readonly errors: string[];
8
- constructor(errors: string[]);
9
- }
10
- /**
11
- * Error thrown when environment detection fails.
12
- */
13
- export declare class EnvironmentDetectionError extends Error {
14
- constructor(message: string);
15
- }
16
- /**
17
- * Unified entry point for Runtime Web Core.
18
- *
19
- * This function provides a single API that works across all execution contexts:
20
- * - **Browser**: Hydrates React application with client-side routing
21
- * - **Lambda**: Executes server-side rendering and business logic with DI
22
- * - **CDK**: Synthesizes CloudFormation infrastructure templates
23
- *
24
- * The function automatically detects the runtime environment and routes
25
- * execution to the appropriate pipeline without user intervention.
26
- *
27
- * **Note**: For Lambda and CDK contexts, use the server-side entry point
28
- * from `@core/runtime-web` instead. This browser-compatible version
29
- * only supports browser hydration.
30
- *
31
- * @param config - Unified configuration for all contexts
32
- * @returns Promise that resolves when execution completes
33
- * @throws ConfigValidationError if configuration is invalid
34
- * @throws EnvironmentDetectionError if environment cannot be detected
35
- * @throws Error if execution fails
36
- *
37
- * @example
38
- * ```typescript
39
- * import { runtime } from '@worktif/runtime/runtime-web';
40
- * import { RuntimeRouter } from '@worktif/runtime';
41
- *
42
- * runtime({
43
- * app: ({ router }) => <App router={router} />,
44
- * router: new RuntimeRouter({ routes, defaults: {} }),
45
- * serviceName: 'my-app',
46
- * stage: 'dev',
47
- * register: {
48
- * payments: {
49
- * ties: [PaymentsTies],
50
- * lambdas: [chargeHandler, refundHandler]
51
- * }
52
- * },
53
- * infra: {
54
- * env: { account: '123456789012', region: 'us-east-1' },
55
- * stage: 'dev',
56
- * reactEntry: './src/index.tsx',
57
- * apiMode: 'apiGateway'
58
- * }
59
- * });
60
- * ```
61
- */
62
- export declare function pureweb(config: RuntimeWebConfig): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@worktif/runtime",
3
- "version": "0.3.0-edge.37",
3
+ "version": "0.3.0-edge.38",
4
4
  "description": "Serverless web framework running on AWS Lambda with support for server-side rendering, caching, and CI/CD.",
5
5
  "repository": "git@bitbucket.org:worktif/runtime-target.git",
6
6
  "author": "Raman Marozau <raman@worktif.com>",