@fougere/core 0.6.0-alpha.0 → 0.7.0-alpha.0
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 +1 -1
- package/dist/boot/Emissions.d.ts +13 -90
- package/dist/boot/Emissions.d.ts.map +1 -1
- package/dist/boot/Emissions.js +21 -118
- package/dist/boot/Emissions.js.map +1 -1
- package/dist/boot/ambient-port.d.ts +3 -24
- package/dist/boot/ambient-port.d.ts.map +1 -1
- package/dist/boot/ambient.als.d.ts.map +1 -1
- package/dist/boot/ambient.als.js +7 -12
- package/dist/boot/ambient.als.js.map +1 -1
- package/dist/boot/ambient.queue.d.ts +2 -5
- package/dist/boot/ambient.queue.d.ts.map +1 -1
- package/dist/boot/ambient.queue.js.map +1 -1
- package/dist/boot/apply.d.ts +1 -13
- package/dist/boot/apply.d.ts.map +1 -1
- package/dist/boot/apply.js +3 -15
- package/dist/boot/apply.js.map +1 -1
- package/dist/boot/auth.d.ts +2 -12
- package/dist/boot/auth.d.ts.map +1 -1
- package/dist/boot/boot.d.ts +3 -16
- package/dist/boot/boot.d.ts.map +1 -1
- package/dist/boot/boot.js +3 -10
- package/dist/boot/boot.js.map +1 -1
- package/dist/boot/bootstrap.d.ts.map +1 -1
- package/dist/boot/bootstrap.js +61 -127
- package/dist/boot/bootstrap.js.map +1 -1
- package/dist/boot/card.d.ts +1 -17
- package/dist/boot/card.d.ts.map +1 -1
- package/dist/boot/card.js +3 -32
- package/dist/boot/card.js.map +1 -1
- package/dist/boot/frame.d.ts +8 -32
- package/dist/boot/frame.d.ts.map +1 -1
- package/dist/boot/frame.js +20 -54
- package/dist/boot/frame.js.map +1 -1
- package/dist/boot/hosted.d.ts +2 -24
- package/dist/boot/hosted.d.ts.map +1 -1
- package/dist/boot/hosted.js +10 -15
- package/dist/boot/hosted.js.map +1 -1
- package/dist/boot/ownership.d.ts +3 -36
- package/dist/boot/ownership.d.ts.map +1 -1
- package/dist/boot/ownership.js +5 -40
- package/dist/boot/ownership.js.map +1 -1
- package/dist/boot/ports.d.ts +1 -14
- package/dist/boot/ports.d.ts.map +1 -1
- package/dist/boot/ports.js +1 -14
- package/dist/boot/ports.js.map +1 -1
- package/dist/boot/remote.d.ts +5 -38
- package/dist/boot/remote.d.ts.map +1 -1
- package/dist/boot/remote.js +8 -41
- package/dist/boot/remote.js.map +1 -1
- package/dist/boot/runner.d.ts +4 -21
- package/dist/boot/runner.d.ts.map +1 -1
- package/dist/boot/runner.js +4 -17
- package/dist/boot/runner.js.map +1 -1
- package/dist/boot/seed.d.ts +4 -31
- package/dist/boot/seed.d.ts.map +1 -1
- package/dist/boot/seed.js +6 -37
- package/dist/boot/seed.js.map +1 -1
- package/dist/boot/statement-drift.d.ts +2 -21
- package/dist/boot/statement-drift.d.ts.map +1 -1
- package/dist/boot/statement-drift.js +4 -9
- package/dist/boot/statement-drift.js.map +1 -1
- package/dist/boot/together.d.ts +4 -8
- package/dist/boot/together.d.ts.map +1 -1
- package/dist/boot/together.js +15 -50
- package/dist/boot/together.js.map +1 -1
- package/dist/boot/types.d.ts +28 -173
- package/dist/boot/types.d.ts.map +1 -1
- package/dist/builtin/config.d.ts +7 -0
- package/dist/builtin/config.d.ts.map +1 -0
- package/dist/builtin/config.js +15 -0
- package/dist/builtin/config.js.map +1 -0
- package/dist/{builtins → builtin}/logger.d.ts +4 -25
- package/dist/builtin/logger.d.ts.map +1 -0
- package/dist/{builtins → builtin}/logger.js +5 -32
- package/dist/builtin/logger.js.map +1 -0
- package/dist/config-loader.d.ts +9 -67
- package/dist/config-loader.d.ts.map +1 -1
- package/dist/config-loader.js +5 -18
- package/dist/config-loader.js.map +1 -1
- package/dist/contract.d.ts +13 -31
- package/dist/contract.d.ts.map +1 -1
- package/dist/contract.js +10 -26
- package/dist/contract.js.map +1 -1
- package/dist/crypto/encoding.d.ts +2 -15
- package/dist/crypto/encoding.d.ts.map +1 -1
- package/dist/crypto/encoding.js +2 -15
- package/dist/crypto/encoding.js.map +1 -1
- package/dist/crypto/node.d.ts.map +1 -1
- package/dist/crypto/node.js +1 -7
- package/dist/crypto/node.js.map +1 -1
- package/dist/crypto/port.d.ts +2 -18
- package/dist/crypto/port.d.ts.map +1 -1
- package/dist/crypto/port.js +1 -17
- package/dist/crypto/port.js.map +1 -1
- package/dist/crypto/webcrypto.d.ts.map +1 -1
- package/dist/crypto/webcrypto.js +1 -12
- package/dist/crypto/webcrypto.js.map +1 -1
- package/dist/declare.d.ts +6 -36
- package/dist/declare.d.ts.map +1 -1
- package/dist/declare.js +4 -29
- package/dist/declare.js.map +1 -1
- package/dist/define.d.ts +2 -3
- package/dist/define.d.ts.map +1 -1
- package/dist/define.js +2 -3
- package/dist/define.js.map +1 -1
- package/dist/descriptor/Fronds.d.ts +3 -28
- package/dist/descriptor/Fronds.d.ts.map +1 -1
- package/dist/descriptor/Fronds.js +6 -31
- package/dist/descriptor/Fronds.js.map +1 -1
- package/dist/descriptor/frond.d.ts +14 -63
- package/dist/descriptor/frond.d.ts.map +1 -1
- package/dist/dispatch/ArgumentResolver.d.ts +1 -1
- package/dist/dispatch/ArgumentResolver.d.ts.map +1 -1
- package/dist/dispatch/ArgumentResolver.js +5 -5
- package/dist/dispatch/ArgumentResolver.js.map +1 -1
- package/dist/dispatch/DispatchEvent.d.ts +2 -2
- package/dist/dispatch/DispatchEvent.d.ts.map +1 -1
- package/dist/dispatch/DispatchLifecycle.d.ts +1 -7
- package/dist/dispatch/DispatchLifecycle.d.ts.map +1 -1
- package/dist/dispatch/DispatchLifecycle.js +1 -7
- package/dist/dispatch/DispatchLifecycle.js.map +1 -1
- package/dist/dispatch/DispatchPort.d.ts +1 -1
- package/dist/dispatch/DispatchPort.d.ts.map +1 -1
- package/dist/dispatch/Dispatcher.d.ts +1 -1
- package/dist/dispatch/Dispatcher.d.ts.map +1 -1
- package/dist/dispatch/Dispatcher.js +2 -2
- package/dist/dispatch/Dispatcher.js.map +1 -1
- package/dist/{boot → dispatch}/HandlerFacade.d.ts +25 -38
- package/dist/dispatch/HandlerFacade.d.ts.map +1 -0
- package/dist/{boot → dispatch}/HandlerFacade.js +65 -74
- package/dist/dispatch/HandlerFacade.js.map +1 -0
- package/dist/dispatch/LocalRoutePolicy.d.ts +1 -1
- package/dist/dispatch/LocalRoutePolicy.d.ts.map +1 -1
- package/dist/dispatch/LocalRoutePolicy.js +4 -4
- package/dist/dispatch/LocalRoutePolicy.js.map +1 -1
- package/dist/dispatch/OperationRoute.d.ts +2 -2
- package/dist/dispatch/OperationRoute.d.ts.map +1 -1
- package/dist/dispatch/OutputView.d.ts +3 -2
- package/dist/dispatch/OutputView.d.ts.map +1 -1
- package/dist/dispatch/OutputView.js +19 -1
- package/dist/dispatch/OutputView.js.map +1 -1
- package/dist/dispatch/Route.d.ts +2 -2
- package/dist/dispatch/Route.d.ts.map +1 -1
- package/dist/dispatch/RoutePolicy.d.ts +1 -1
- package/dist/dispatch/RoutePolicy.d.ts.map +1 -1
- package/dist/dispatch/RouteRegistry.d.ts +1 -1
- package/dist/dispatch/RouteRegistry.d.ts.map +1 -1
- package/dist/dispatch/RouteRegistry.js +2 -2
- package/dist/dispatch/RouteRegistry.js.map +1 -1
- package/dist/dispatch/RouteResolver.d.ts +2 -4
- package/dist/dispatch/RouteResolver.d.ts.map +1 -1
- package/dist/dispatch/StorageGuard.d.ts +8 -7
- package/dist/dispatch/StorageGuard.d.ts.map +1 -1
- package/dist/dispatch/StorageGuard.js +61 -18
- package/dist/dispatch/StorageGuard.js.map +1 -1
- package/dist/dispatch/presenterArguments.d.ts +7 -0
- package/dist/dispatch/presenterArguments.d.ts.map +1 -0
- package/dist/dispatch/presenterArguments.js +12 -0
- package/dist/dispatch/presenterArguments.js.map +1 -0
- package/dist/dispatch/remoteRoutes.d.ts +7 -0
- package/dist/dispatch/remoteRoutes.d.ts.map +1 -0
- package/dist/dispatch/{RemoteRouteResolver.js → remoteRoutes.js} +6 -10
- package/dist/dispatch/remoteRoutes.js.map +1 -0
- package/dist/dispatch/routeNotFound.d.ts +9 -0
- package/dist/dispatch/routeNotFound.d.ts.map +1 -0
- package/dist/dispatch/routeNotFound.js +21 -0
- package/dist/dispatch/routeNotFound.js.map +1 -0
- package/dist/dispatch/validateInput.d.ts +5 -0
- package/dist/dispatch/validateInput.d.ts.map +1 -0
- package/dist/dispatch/validateInput.js +20 -0
- package/dist/dispatch/validateInput.js.map +1 -0
- package/dist/effective-operation.d.ts +1 -24
- package/dist/effective-operation.d.ts.map +1 -1
- package/dist/effective-operation.js +21 -50
- package/dist/effective-operation.js.map +1 -1
- package/dist/emit.d.ts +4 -42
- package/dist/emit.d.ts.map +1 -1
- package/dist/emit.js +3 -39
- package/dist/emit.js.map +1 -1
- package/dist/entry/facade.d.ts +8 -0
- package/dist/entry/facade.d.ts.map +1 -0
- package/dist/entry/facade.js +28 -0
- package/dist/entry/facade.js.map +1 -0
- package/dist/entry/transport.d.ts +5 -0
- package/dist/entry/transport.d.ts.map +1 -0
- package/dist/entry/transport.js +11 -0
- package/dist/entry/transport.js.map +1 -0
- package/dist/frond-config.d.ts +7 -70
- package/dist/frond-config.d.ts.map +1 -1
- package/dist/frond-config.js +1 -9
- package/dist/frond-config.js.map +1 -1
- package/dist/identity-keys.d.ts +2 -5
- package/dist/identity-keys.d.ts.map +1 -1
- package/dist/identity-keys.js +3 -16
- package/dist/identity-keys.js.map +1 -1
- package/dist/identity.d.ts +4 -30
- package/dist/identity.d.ts.map +1 -1
- package/dist/identity.js +11 -73
- package/dist/identity.js.map +1 -1
- package/dist/imports.d.ts +1 -7
- package/dist/imports.d.ts.map +1 -1
- package/dist/imports.js +1 -7
- package/dist/imports.js.map +1 -1
- package/dist/index.d.ts +17 -24
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +10 -18
- package/dist/index.js.map +1 -1
- package/dist/loader.d.ts +1 -8
- package/dist/loader.d.ts.map +1 -1
- package/dist/loader.js +1 -8
- package/dist/loader.js.map +1 -1
- package/dist/node.d.ts +2 -11
- package/dist/node.d.ts.map +1 -1
- package/dist/node.js +2 -11
- package/dist/node.js.map +1 -1
- package/dist/prefab/collector.d.ts +1 -22
- package/dist/prefab/collector.d.ts.map +1 -1
- package/dist/prefab/collector.js +1 -22
- package/dist/prefab/collector.js.map +1 -1
- package/dist/prefab/crud.d.ts +16 -32
- package/dist/prefab/crud.d.ts.map +1 -1
- package/dist/prefab/crud.js +31 -58
- package/dist/prefab/crud.js.map +1 -1
- package/dist/prefab/mirror.d.ts +2 -24
- package/dist/prefab/mirror.d.ts.map +1 -1
- package/dist/prefab/mirror.js +2 -20
- package/dist/prefab/mirror.js.map +1 -1
- package/dist/prefab/prefab.d.ts +1 -7
- package/dist/prefab/prefab.d.ts.map +1 -1
- package/dist/prefab/prefab.js +1 -7
- package/dist/prefab/prefab.js.map +1 -1
- package/dist/prefab/presenter.d.ts +2 -36
- package/dist/prefab/presenter.d.ts.map +1 -1
- package/dist/prefab/presenter.js +2 -36
- package/dist/prefab/presenter.js.map +1 -1
- package/dist/prefab/repository.d.ts +5 -73
- package/dist/prefab/repository.d.ts.map +1 -1
- package/dist/prefab/repository.js +3 -16
- package/dist/prefab/repository.js.map +1 -1
- package/dist/scan/adapters.d.ts +3 -0
- package/dist/scan/adapters.d.ts.map +1 -0
- package/dist/scan/adapters.js +25 -0
- package/dist/scan/adapters.js.map +1 -0
- package/dist/scan/bundling.d.ts +1 -12
- package/dist/scan/bundling.d.ts.map +1 -1
- package/dist/scan/bundling.js +1 -12
- package/dist/scan/bundling.js.map +1 -1
- package/dist/scan/conventions.d.ts +6 -40
- package/dist/scan/conventions.d.ts.map +1 -1
- package/dist/scan/conventions.js +5 -34
- package/dist/scan/conventions.js.map +1 -1
- package/dist/scan/emit.d.ts +1 -5
- package/dist/scan/emit.d.ts.map +1 -1
- package/dist/scan/emit.js +4 -38
- package/dist/scan/emit.js.map +1 -1
- package/dist/scan/handler-parser.d.ts +4 -26
- package/dist/scan/handler-parser.d.ts.map +1 -1
- package/dist/scan/handler-parser.js +26 -83
- package/dist/scan/handler-parser.js.map +1 -1
- package/dist/scan/result.d.ts +3 -16
- package/dist/scan/result.d.ts.map +1 -1
- package/dist/scan/scanner.d.ts +2 -27
- package/dist/scan/scanner.d.ts.map +1 -1
- package/dist/scan/scanner.js +28 -127
- package/dist/scan/scanner.js.map +1 -1
- package/dist/scan/statement.d.ts.map +1 -1
- package/dist/scan/statement.js +4 -30
- package/dist/scan/statement.js.map +1 -1
- package/dist/source.d.ts +41 -0
- package/dist/source.d.ts.map +1 -0
- package/dist/source.js +10 -0
- package/dist/source.js.map +1 -0
- package/dist/storage.d.ts +13 -210
- package/dist/storage.d.ts.map +1 -1
- package/dist/storage.js +4 -68
- package/dist/storage.js.map +1 -1
- package/dist/store.d.ts +18 -0
- package/dist/store.d.ts.map +1 -0
- package/dist/store.js +146 -0
- package/dist/store.js.map +1 -0
- package/dist/verify.d.ts +5 -38
- package/dist/verify.d.ts.map +1 -1
- package/dist/verify.js +17 -37
- package/dist/verify.js.map +1 -1
- package/dist/wire/CallLog.d.ts +32 -0
- package/dist/wire/CallLog.d.ts.map +1 -0
- package/dist/{contract → wire}/CallLog.js.map +1 -1
- package/dist/wire/Invocation.d.ts +32 -0
- package/dist/wire/Invocation.d.ts.map +1 -0
- package/dist/wire/Invocation.js +66 -0
- package/dist/wire/Invocation.js.map +1 -0
- package/dist/{contract → wire}/RouteAddress.d.ts +5 -0
- package/dist/wire/RouteAddress.d.ts.map +1 -0
- package/dist/{contract → wire}/RouteAddress.js +7 -0
- package/dist/wire/RouteAddress.js.map +1 -0
- package/dist/wire/binding.d.ts +5 -21
- package/dist/wire/binding.d.ts.map +1 -1
- package/dist/wire/binding.js +5 -10
- package/dist/wire/binding.js.map +1 -1
- package/dist/wire/call.d.ts +24 -133
- package/dist/wire/call.d.ts.map +1 -1
- package/dist/wire/call.js +15 -41
- package/dist/wire/call.js.map +1 -1
- package/dist/wire/drift.d.ts +3 -28
- package/dist/wire/drift.d.ts.map +1 -1
- package/dist/wire/drift.js +4 -23
- package/dist/wire/drift.js.map +1 -1
- package/dist/wire/errors.d.ts +4 -24
- package/dist/wire/errors.d.ts.map +1 -1
- package/dist/wire/errors.js +4 -24
- package/dist/wire/errors.js.map +1 -1
- package/dist/wire/http-error.d.ts +2 -13
- package/dist/wire/http-error.d.ts.map +1 -1
- package/dist/wire/http-error.js +5 -19
- package/dist/wire/http-error.js.map +1 -1
- package/dist/wire/loggerMiddleware.d.ts +2 -8
- package/dist/wire/loggerMiddleware.d.ts.map +1 -1
- package/dist/wire/loggerMiddleware.js +1 -7
- package/dist/wire/loggerMiddleware.js.map +1 -1
- package/dist/wire/middleware.d.ts +3 -7
- package/dist/wire/middleware.d.ts.map +1 -1
- package/dist/wire/middleware.js +1 -5
- package/dist/wire/middleware.js.map +1 -1
- package/dist/wire/operation.d.ts +7 -43
- package/dist/wire/operation.d.ts.map +1 -1
- package/dist/wire/operation.js +4 -15
- package/dist/wire/operation.js.map +1 -1
- package/dist/wire/signature.d.ts +4 -25
- package/dist/wire/signature.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/boot/Emissions.ts +21 -118
- package/src/boot/ambient-port.ts +3 -24
- package/src/boot/ambient.als.ts +7 -12
- package/src/boot/ambient.queue.ts +2 -5
- package/src/boot/apply.ts +3 -15
- package/src/boot/auth.ts +2 -12
- package/src/boot/boot.ts +5 -20
- package/src/boot/bootstrap.ts +69 -136
- package/src/boot/card.ts +4 -33
- package/src/boot/frame.ts +28 -62
- package/src/boot/hosted.ts +12 -34
- package/src/boot/ownership.ts +5 -39
- package/src/boot/ports.ts +1 -14
- package/src/boot/remote.ts +11 -58
- package/src/boot/runner.ts +5 -22
- package/src/boot/seed.ts +6 -37
- package/src/boot/statement-drift.ts +5 -24
- package/src/boot/together.ts +18 -51
- package/src/boot/types.ts +28 -173
- package/src/{builtins → builtin}/config.ts +1 -7
- package/src/{builtins → builtin}/logger.ts +6 -39
- package/src/config-loader.ts +12 -71
- package/src/contract.ts +15 -39
- package/src/crypto/encoding.ts +2 -15
- package/src/crypto/node.ts +1 -7
- package/src/crypto/port.ts +2 -18
- package/src/crypto/webcrypto.ts +1 -12
- package/src/declare.ts +8 -39
- package/src/define.ts +2 -3
- package/src/descriptor/Fronds.ts +6 -31
- package/src/descriptor/frond.ts +14 -63
- package/src/dispatch/ArgumentResolver.ts +6 -6
- package/src/dispatch/DispatchEvent.ts +2 -2
- package/src/dispatch/DispatchLifecycle.ts +1 -7
- package/src/dispatch/DispatchPort.ts +1 -1
- package/src/dispatch/Dispatcher.ts +3 -3
- package/src/dispatch/HandlerFacade.ts +231 -0
- package/src/dispatch/LocalRoutePolicy.ts +4 -4
- package/src/dispatch/OperationRoute.ts +2 -2
- package/src/dispatch/OutputView.ts +24 -2
- package/src/dispatch/Route.ts +2 -2
- package/src/dispatch/RoutePolicy.ts +1 -1
- package/src/dispatch/RouteRegistry.ts +2 -2
- package/src/dispatch/RouteResolver.ts +2 -4
- package/src/dispatch/StorageGuard.ts +70 -18
- package/src/dispatch/presenterArguments.ts +25 -0
- package/src/dispatch/{RemoteRouteResolver.ts → remoteRoutes.ts} +7 -9
- package/src/dispatch/routeNotFound.ts +33 -0
- package/src/dispatch/validateInput.ts +28 -0
- package/src/effective-operation.ts +21 -50
- package/src/emit.ts +5 -63
- package/src/entry/facade.ts +44 -0
- package/src/entry/transport.ts +16 -0
- package/src/frond-config.ts +7 -70
- package/src/identity-keys.ts +3 -16
- package/src/identity.ts +12 -80
- package/src/imports.ts +2 -31
- package/src/index.ts +17 -24
- package/src/loader.ts +2 -16
- package/src/node.ts +2 -11
- package/src/prefab/collector.ts +1 -22
- package/src/prefab/crud.ts +37 -76
- package/src/prefab/mirror.ts +4 -44
- package/src/prefab/prefab.ts +2 -21
- package/src/prefab/presenter.ts +2 -36
- package/src/prefab/repository.ts +7 -83
- package/src/scan/adapters.ts +32 -0
- package/src/scan/bundling.ts +1 -12
- package/src/scan/conventions.ts +6 -40
- package/src/scan/emit.ts +4 -38
- package/src/scan/handler-parser.ts +27 -96
- package/src/scan/result.ts +3 -16
- package/src/scan/scanner.ts +27 -126
- package/src/scan/statement.ts +4 -30
- package/src/source.ts +44 -0
- package/src/storage.ts +14 -234
- package/src/store.ts +152 -0
- package/src/verify.ts +16 -57
- package/src/wire/CallLog.ts +30 -0
- package/src/{contract → wire}/Invocation.ts +24 -17
- package/src/{contract → wire}/RouteAddress.ts +7 -0
- package/src/wire/binding.ts +9 -25
- package/src/wire/call.ts +30 -133
- package/src/wire/drift.ts +5 -30
- package/src/wire/errors.ts +4 -24
- package/src/wire/http-error.ts +5 -19
- package/src/wire/loggerMiddleware.ts +2 -8
- package/src/wire/middleware.ts +3 -7
- package/src/wire/operation.ts +8 -48
- package/src/wire/signature.ts +4 -25
- package/dist/boot/HandlerFacade.d.ts.map +0 -1
- package/dist/boot/HandlerFacade.js.map +0 -1
- package/dist/builtins/config.d.ts +0 -13
- package/dist/builtins/config.d.ts.map +0 -1
- package/dist/builtins/config.js +0 -21
- package/dist/builtins/config.js.map +0 -1
- package/dist/builtins/logger.d.ts.map +0 -1
- package/dist/builtins/logger.js.map +0 -1
- package/dist/contract/Call.d.ts +0 -10
- package/dist/contract/Call.d.ts.map +0 -1
- package/dist/contract/Call.js +0 -15
- package/dist/contract/Call.js.map +0 -1
- package/dist/contract/CallLog.d.ts +0 -57
- package/dist/contract/CallLog.d.ts.map +0 -1
- package/dist/contract/Invocation.d.ts +0 -27
- package/dist/contract/Invocation.d.ts.map +0 -1
- package/dist/contract/Invocation.js +0 -59
- package/dist/contract/Invocation.js.map +0 -1
- package/dist/contract/RouteAddress.d.ts.map +0 -1
- package/dist/contract/RouteAddress.js.map +0 -1
- package/dist/dispatch/InputValidator.d.ts +0 -7
- package/dist/dispatch/InputValidator.d.ts.map +0 -1
- package/dist/dispatch/InputValidator.js +0 -22
- package/dist/dispatch/InputValidator.js.map +0 -1
- package/dist/dispatch/OperationExecutor.d.ts +0 -25
- package/dist/dispatch/OperationExecutor.d.ts.map +0 -1
- package/dist/dispatch/OperationExecutor.js +0 -32
- package/dist/dispatch/OperationExecutor.js.map +0 -1
- package/dist/dispatch/OutputProjector.d.ts +0 -12
- package/dist/dispatch/OutputProjector.d.ts.map +0 -1
- package/dist/dispatch/OutputProjector.js +0 -30
- package/dist/dispatch/OutputProjector.js.map +0 -1
- package/dist/dispatch/PresenterArgumentResolver.d.ts +0 -12
- package/dist/dispatch/PresenterArgumentResolver.d.ts.map +0 -1
- package/dist/dispatch/PresenterArgumentResolver.js +0 -20
- package/dist/dispatch/PresenterArgumentResolver.js.map +0 -1
- package/dist/dispatch/RemoteRouteResolver.d.ts +0 -13
- package/dist/dispatch/RemoteRouteResolver.d.ts.map +0 -1
- package/dist/dispatch/RemoteRouteResolver.js.map +0 -1
- package/dist/dispatch/RouteNotFoundError.d.ts +0 -10
- package/dist/dispatch/RouteNotFoundError.d.ts.map +0 -1
- package/dist/dispatch/RouteNotFoundError.js +0 -24
- package/dist/dispatch/RouteNotFoundError.js.map +0 -1
- package/dist/entry/DynamicFacade.d.ts +0 -10
- package/dist/entry/DynamicFacade.d.ts.map +0 -1
- package/dist/entry/DynamicFacade.js +0 -27
- package/dist/entry/DynamicFacade.js.map +0 -1
- package/dist/entry/FacadeEntry.d.ts +0 -11
- package/dist/entry/FacadeEntry.d.ts.map +0 -1
- package/dist/entry/FacadeEntry.js +0 -26
- package/dist/entry/FacadeEntry.js.map +0 -1
- package/dist/entry/TransportEntry.d.ts +0 -13
- package/dist/entry/TransportEntry.d.ts.map +0 -1
- package/dist/entry/TransportEntry.js +0 -24
- package/dist/entry/TransportEntry.js.map +0 -1
- package/dist/rows.d.ts +0 -40
- package/dist/rows.d.ts.map +0 -1
- package/dist/rows.js +0 -146
- package/dist/rows.js.map +0 -1
- package/src/boot/HandlerFacade.ts +0 -242
- package/src/contract/Call.ts +0 -18
- package/src/contract/CallLog.ts +0 -55
- package/src/dispatch/InputValidator.ts +0 -28
- package/src/dispatch/OperationExecutor.ts +0 -60
- package/src/dispatch/OutputProjector.ts +0 -32
- package/src/dispatch/PresenterArgumentResolver.ts +0 -25
- package/src/dispatch/RouteNotFoundError.ts +0 -29
- package/src/entry/DynamicFacade.ts +0 -28
- package/src/entry/FacadeEntry.ts +0 -32
- package/src/entry/TransportEntry.ts +0 -30
- package/src/rows.ts +0 -155
- /package/dist/{contract → wire}/CallLog.js +0 -0
|
@@ -1,45 +1,11 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Presenter(Entity) — enriches an entity's output with computed fields.
|
|
3
|
-
*
|
|
4
|
-
* Each method on the presenter is a computed field resolver:
|
|
5
|
-
* - Receives the entity record as first argument
|
|
6
|
-
* - Can be sync or async
|
|
7
|
-
* - Injected via DI (constructor params resolved by the container)
|
|
8
|
-
*
|
|
9
|
-
* Usage:
|
|
10
|
-
* ```ts
|
|
11
|
-
* export default class PostPresenter extends Presenter(Post) {
|
|
12
|
-
* constructor(private commentStorage: CommentStorage) { super(); }
|
|
13
|
-
*
|
|
14
|
-
* excerpt(post: Post) {
|
|
15
|
-
* return post.body.slice(0, 200);
|
|
16
|
-
* }
|
|
17
|
-
*
|
|
18
|
-
* async commentCount(post: Post) {
|
|
19
|
-
* return this.commentStorage.countFor(post.id);
|
|
20
|
-
* }
|
|
21
|
-
* }
|
|
22
|
-
* ```
|
|
23
|
-
*/
|
|
1
|
+
/** Presenter(Entity) — enriches an entity's output with computed fields. */
|
|
24
2
|
import { type EntityConstructor } from '@fougere/schema';
|
|
25
3
|
/**
|
|
26
4
|
* The view a computed field emits — `OrderItemView` for one, `[OrderItemView]` for many.
|
|
27
5
|
* A view is a schema, so it derives: `Order.pick('id', 'status')`, never a hand-written type.
|
|
28
6
|
*/
|
|
29
7
|
export type PresenterViews = Record<string, EntityConstructor | [EntityConstructor]>;
|
|
30
|
-
/**
|
|
31
|
-
* `Presenter(Order, { items: [OrderItemView], user: UserCard })` — the second argument names
|
|
32
|
-
* the view each computed field emits, exactly as `Crud(Post, { list: PostCard })` names an
|
|
33
|
-
* op's. What fabricates a field declares its contract, and it declares it **once**: the
|
|
34
|
-
* façade applies the presenter (see `PresenterExecutor`), and every surface reads the same statement
|
|
35
|
-
* instead of guessing.
|
|
36
|
-
*
|
|
37
|
-
* Guessing was the cost of not stating it. The scan can read a scalar off a return type and
|
|
38
|
-
* nothing more, so a field returning an object had no derivable shape: the GraphQL projection
|
|
39
|
-
* fell back to a serialized `String`, and a client asking `items { quantity }` got a schema
|
|
40
|
-
* error on a field REST served whole. Declaring is optional — a scalar field needs nothing,
|
|
41
|
-
* and an undeclared object keeps the old behaviour.
|
|
42
|
-
*/
|
|
8
|
+
/** `Presenter(Order, { items. */
|
|
43
9
|
export declare function Presenter<E extends EntityConstructor>(entity: E, views?: PresenterViews): {
|
|
44
10
|
new (): {};
|
|
45
11
|
readonly __entity: E;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"presenter.d.ts","sourceRoot":"","sources":["../../src/prefab/presenter.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"presenter.d.ts","sourceRoot":"","sources":["../../src/prefab/presenter.ts"],"names":[],"mappings":"AAAA,4EAA4E;AAE5E,OAAO,EAAc,KAAK,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAErE;;;GAGG;AACH,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,iBAAiB,GAAG,CAAC,iBAAiB,CAAC,CAAC,CAAC;AAErF,iCAAiC;AACjC,wBAAgB,SAAS,CAAC,CAAC,SAAS,iBAAiB,EAAE,MAAM,EAAE,CAAC,EAAE,KAAK,CAAC,EAAE,cAAc;;;;EAMvF;AAED,wFAAwF;AACxF,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,QAAQ,GAAG,MAAM,EAAE,CAG3D;AAED,yEAAyE;AACzE,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAErD"}
|
package/dist/prefab/presenter.js
CHANGED
|
@@ -1,40 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Presenter(Entity) — enriches an entity's output with computed fields.
|
|
3
|
-
*
|
|
4
|
-
* Each method on the presenter is a computed field resolver:
|
|
5
|
-
* - Receives the entity record as first argument
|
|
6
|
-
* - Can be sync or async
|
|
7
|
-
* - Injected via DI (constructor params resolved by the container)
|
|
8
|
-
*
|
|
9
|
-
* Usage:
|
|
10
|
-
* ```ts
|
|
11
|
-
* export default class PostPresenter extends Presenter(Post) {
|
|
12
|
-
* constructor(private commentStorage: CommentStorage) { super(); }
|
|
13
|
-
*
|
|
14
|
-
* excerpt(post: Post) {
|
|
15
|
-
* return post.body.slice(0, 200);
|
|
16
|
-
* }
|
|
17
|
-
*
|
|
18
|
-
* async commentCount(post: Post) {
|
|
19
|
-
* return this.commentStorage.countFor(post.id);
|
|
20
|
-
* }
|
|
21
|
-
* }
|
|
22
|
-
* ```
|
|
23
|
-
*/
|
|
1
|
+
/** Presenter(Entity) — enriches an entity's output with computed fields. */
|
|
24
2
|
import { upperFirst } from '@fougere/schema';
|
|
25
|
-
/**
|
|
26
|
-
* `Presenter(Order, { items: [OrderItemView], user: UserCard })` — the second argument names
|
|
27
|
-
* the view each computed field emits, exactly as `Crud(Post, { list: PostCard })` names an
|
|
28
|
-
* op's. What fabricates a field declares its contract, and it declares it **once**: the
|
|
29
|
-
* façade applies the presenter (see `PresenterExecutor`), and every surface reads the same statement
|
|
30
|
-
* instead of guessing.
|
|
31
|
-
*
|
|
32
|
-
* Guessing was the cost of not stating it. The scan can read a scalar off a return type and
|
|
33
|
-
* nothing more, so a field returning an object had no derivable shape: the GraphQL projection
|
|
34
|
-
* fell back to a serialized `String`, and a client asking `items { quantity }` got a schema
|
|
35
|
-
* error on a field REST served whole. Declaring is optional — a scalar field needs nothing,
|
|
36
|
-
* and an undeclared object keeps the old behaviour.
|
|
37
|
-
*/
|
|
3
|
+
/** `Presenter(Order, { items. */
|
|
38
4
|
export function Presenter(entity, views) {
|
|
39
5
|
class PresenterBase {
|
|
40
6
|
static __entity = entity;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"presenter.js","sourceRoot":"","sources":["../../src/prefab/presenter.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"presenter.js","sourceRoot":"","sources":["../../src/prefab/presenter.ts"],"names":[],"mappings":"AAAA,4EAA4E;AAE5E,OAAO,EAAE,UAAU,EAA0B,MAAM,iBAAiB,CAAC;AAQrE,iCAAiC;AACjC,MAAM,UAAU,SAAS,CAA8B,MAAS,EAAE,KAAsB;IACtF,MAAM,aAAa;QACjB,MAAM,CAAU,QAAQ,GAAG,MAAM,CAAC;QAClC,MAAM,CAAU,OAAO,GAAG,KAAK,CAAC;;IAElC,OAAO,aAAa,CAAC;AACvB,CAAC;AAED,wFAAwF;AACxF,MAAM,UAAU,kBAAkB,CAAC,IAAc;IAC/C,OAAO,MAAM,CAAC,mBAAmB,CAAC,IAAI,CAAC,SAAS,CAAC;SAC9C,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,KAAK,aAAa,IAAI,OAAO,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,KAAK,UAAU,CAAC,CAAC;AAC5F,CAAC;AAED,yEAAyE;AACzE,MAAM,UAAU,cAAc,CAAC,MAAc;IAC3C,OAAO,GAAG,UAAU,CAAC,MAAM,CAAC,WAAW,CAAC;AAC1C,CAAC"}
|
|
@@ -1,66 +1,9 @@
|
|
|
1
1
|
import { type EntityConstructor } from '@fougere/schema';
|
|
2
2
|
import type { Storage } from '../storage.js';
|
|
3
|
+
/** Repository(…entities) — who owns an entity's storage, and where its questions are named. */
|
|
3
4
|
/**
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
* **The arity decides**, which is the second reading of what `storage.ts` already states for
|
|
7
|
-
* `Storage` against `Together`: the arity of the unit is the whole distinction.
|
|
8
|
-
*
|
|
9
|
-
* ONE entity — the repository IS that entity's storage, with your methods added. The port's
|
|
10
|
-
* thirteen gestures are forwarded, so a handler reads `this.posts.list()` whether or not
|
|
11
|
-
* anyone wrote the file, and a named question sits beside them:
|
|
12
|
-
*
|
|
13
|
-
* ```ts
|
|
14
|
-
* // repositories/PostRepository.ts
|
|
15
|
-
* export default class PostRepository extends Repository(Post) {
|
|
16
|
-
* published() {
|
|
17
|
-
* return this.list({ where: { status: 'published' }, orderBy: 'publishedAt', order: 'desc' });
|
|
18
|
-
* }
|
|
19
|
-
* }
|
|
20
|
-
* ```
|
|
21
|
-
*
|
|
22
|
-
* TWO OR MORE — an aggregate. It owns them: nothing else in the app is handed their
|
|
23
|
-
* storage, and no gesture is forwarded (which entity would `create` write to?), so the only
|
|
24
|
-
* way in is a method this class names. That is what lets a rule spanning two tables exist:
|
|
25
|
-
* it is ordinary TypeScript inside the method that does the writing.
|
|
26
|
-
*
|
|
27
|
-
* ```ts
|
|
28
|
-
* // repositories/CommandeRepository.ts
|
|
29
|
-
* export default class CommandeRepository extends Repository(Commande, Stock) {
|
|
30
|
-
* avecLignes(id: string) {
|
|
31
|
-
* const [commandes, stock] = this.storages;
|
|
32
|
-
* …
|
|
33
|
-
* }
|
|
34
|
-
* }
|
|
35
|
-
* ```
|
|
36
|
-
*
|
|
37
|
-
* `this.storages` is protected, because the whole point is that the storage stops at this file.
|
|
38
|
-
* `protected` is erased at runtime, like `abstract` on a port: a compile-time guarantee, not
|
|
39
|
-
* a barrier. The same bargain, already accepted.
|
|
40
|
-
*
|
|
41
|
-
* **The boundary is not the unit of work.** An aggregate says the rules of these entities
|
|
42
|
-
* hold together; a frame says these writes land together, and the two lists coincide only
|
|
43
|
-
* often. Deriving the frame from the membership would make a read-only aggregate carry one
|
|
44
|
-
* — refusals included, and `registerFrames` refuses without storage or over `remotes:` —
|
|
45
|
-
* and would put `Together<[Commande, Stock], [StockMirror]>` out of reach forever. So a
|
|
46
|
-
* frame is ASKED FOR here as anywhere else, which is what makes it declared:
|
|
47
|
-
*
|
|
48
|
-
* ```ts
|
|
49
|
-
* constructor(commandes: CommandeStorage, stock: StockStorage, private frame: Together<[Commande, Stock]>) {
|
|
50
|
-
* super(commandes, stock);
|
|
51
|
-
* }
|
|
52
|
-
* ```
|
|
53
|
-
*
|
|
54
|
-
* The storage words come back in that line, and only there: this class IS the holder, which is
|
|
55
|
-
* the one case `boot/ownership.ts` lets name the storage it was built on.
|
|
56
|
-
*
|
|
57
|
-
* A repository is NOT a door: it has no façade, so nothing here is reachable from the wire.
|
|
58
|
-
*/
|
|
59
|
-
/**
|
|
60
|
-
* The shape a repository of ONE entity has — the port itself, plus whatever the subclass
|
|
61
|
-
* names on top. Written by an author who has not written the file: `RepositoryOf<Post>` is
|
|
62
|
-
* to `PostRepository` what `Storage<Post>` is to `PostStorage`, one spelling of one key, and
|
|
63
|
-
* `depKeyOf` reads both.
|
|
5
|
+
* The shape a repository of ONE entity has — the port itself, plus whatever the subclass names on
|
|
6
|
+
* top.
|
|
64
7
|
*/
|
|
65
8
|
export type RepositoryOf<T> = Storage<T>;
|
|
66
9
|
/** The single-entity form: the port, plus whatever the subclass names. */
|
|
@@ -68,13 +11,7 @@ export interface RepositoryConstructor<T> {
|
|
|
68
11
|
new (storage: Storage<T>): Storage<T>;
|
|
69
12
|
readonly __entity: unknown;
|
|
70
13
|
}
|
|
71
|
-
/**
|
|
72
|
-
* What an aggregate's subclass sees: the storage of the members it owns, in declared order,
|
|
73
|
-
* and `protected` — the storage stops at that file, which is the whole mechanism.
|
|
74
|
-
*
|
|
75
|
-
* A class and not an interface, because `protected` cannot be spelled in one. Ambient: the
|
|
76
|
-
* value it describes is fabricated by `many()` for an arity only known at the call.
|
|
77
|
-
*/
|
|
14
|
+
/** What an aggregate's subclass sees. */
|
|
78
15
|
declare abstract class AggregateShape<E extends readonly EntityConstructor[]> {
|
|
79
16
|
protected storages: {
|
|
80
17
|
[K in keyof E]: Storage<InstanceType<E[K]>>;
|
|
@@ -93,12 +30,7 @@ export declare function Repository<E extends EntityConstructor>(entity: E): Repo
|
|
|
93
30
|
export declare function Repository<E extends readonly [EntityConstructor, EntityConstructor, ...EntityConstructor[]]>(...entities: E): AggregateConstructor<E>;
|
|
94
31
|
/** Container key of an entity's repository — 'reading' → 'ReadingRepository'. */
|
|
95
32
|
export declare function repositoryKeyOf(entity: string): string;
|
|
96
|
-
/**
|
|
97
|
-
* The entities a class owns — empty for anything that is not an aggregate.
|
|
98
|
-
*
|
|
99
|
-
* Read from the mark rather than from the constructor, for the reason `Crud.__ops` exists:
|
|
100
|
-
* the AST scan is workspace-only, so an installed prefab resolves to nothing.
|
|
101
|
-
*/
|
|
33
|
+
/** The entities a class owns — empty for anything that is not an aggregate. */
|
|
102
34
|
export declare function ownedBy(ctor: unknown): readonly EntityConstructor[];
|
|
103
35
|
export {};
|
|
104
36
|
//# sourceMappingURL=repository.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"repository.d.ts","sourceRoot":"","sources":["../../src/prefab/repository.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,KAAK,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACrE,OAAO,KAAK,EAAE,OAAO,EAAyC,MAAM,eAAe,CAAC;AAGpF
|
|
1
|
+
{"version":3,"file":"repository.d.ts","sourceRoot":"","sources":["../../src/prefab/repository.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,KAAK,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACrE,OAAO,KAAK,EAAE,OAAO,EAAyC,MAAM,eAAe,CAAC;AAGpF,+FAA+F;AAE/F;;;GAGG;AACH,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI,OAAO,CAAC,CAAC,CAAC,CAAC;AAEzC,0EAA0E;AAC1E,MAAM,WAAW,qBAAqB,CAAC,CAAC;IACtC,KAAK,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC;IACtC,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;CAC5B;AAED,yCAAyC;AACzC,OAAO,CAAC,QAAQ,OAAO,cAAc,CA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entities[0]) : many(entities);
|
|
4
4
|
}
|
|
5
|
-
/**
|
|
6
|
-
* The port forwarded, member by member. Written out rather than proxied: a Proxy would
|
|
7
|
-
* answer every name including the ones the port does not have, and this file would then
|
|
8
|
-
* state the surface nowhere. Thirteen lines against one declaration that can be read.
|
|
9
|
-
*/
|
|
5
|
+
/** The port forwarded, member by member. */
|
|
10
6
|
function one(entity) {
|
|
11
7
|
class RepositoryBase {
|
|
12
8
|
storage;
|
|
@@ -30,11 +26,7 @@ function one(entity) {
|
|
|
30
26
|
}
|
|
31
27
|
return RepositoryBase;
|
|
32
28
|
}
|
|
33
|
-
/**
|
|
34
|
-
* The aggregate. Its constructor takes the members' storage in the DECLARED order — the
|
|
35
|
-
* order `toProvider` fills its `deps` with, and the order a subclass hands back to `super()`
|
|
36
|
-
* when it declares a constructor of its own.
|
|
37
|
-
*/
|
|
29
|
+
/** The aggregate. */
|
|
38
30
|
function many(entities) {
|
|
39
31
|
class AggregateBase {
|
|
40
32
|
static __entity = entities[0];
|
|
@@ -50,12 +42,7 @@ function many(entities) {
|
|
|
50
42
|
export function repositoryKeyOf(entity) {
|
|
51
43
|
return `${upperFirst(entity)}Repository`;
|
|
52
44
|
}
|
|
53
|
-
/**
|
|
54
|
-
* The entities a class owns — empty for anything that is not an aggregate.
|
|
55
|
-
*
|
|
56
|
-
* Read from the mark rather than from the constructor, for the reason `Crud.__ops` exists:
|
|
57
|
-
* the AST scan is workspace-only, so an installed prefab resolves to nothing.
|
|
58
|
-
*/
|
|
45
|
+
/** The entities a class owns — empty for anything that is not an aggregate. */
|
|
59
46
|
export function ownedBy(ctor) {
|
|
60
47
|
return ctor?.__owns ?? [];
|
|
61
48
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"repository.js","sourceRoot":"","sources":["../../src/prefab/repository.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAA0B,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"repository.js","source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GH,OAAO,aAAmD,CAAC;AAC7D,CAAC;AAED,iFAAiF;AACjF,MAAM,UAAU,eAAe,CAAC,MAAc;IAC5C,OAAO,GAAG,UAAU,CAAC,MAAM,CAAC,YAAY,CAAC;AAC3C,CAAC;AAED,+EAA+E;AAC/E,MAAM,UAAU,OAAO,CAAC,IAAa;IACnC,OAAQ,IAA8D,EAAE,MAAM,IAAI,EAAE,CAAC;AACvF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"adapters.d.ts","sourceRoot":"","sources":["../../src/scan/adapters.ts"],"names":[],"mappings":"AAMA,6FAA6F;AAC7F,wBAAsB,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAShE"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { readFile } from 'node:fs/promises';
|
|
2
|
+
import { join } from 'node:path';
|
|
3
|
+
/** Which adapters a PROJECT could load, read off its dependencies. */
|
|
4
|
+
const ADAPTER_PACKAGE = /^@fougere\/adapter-(.+)$/;
|
|
5
|
+
/** The adapter names this project depends on — empty when it has no package.json to read. */
|
|
6
|
+
export async function adaptersOf(root) {
|
|
7
|
+
const manifest = await read(join(root, 'package.json'));
|
|
8
|
+
if (!manifest)
|
|
9
|
+
return [];
|
|
10
|
+
const declared = { ...manifest.dependencies, ...manifest.devDependencies };
|
|
11
|
+
return Object.keys(declared)
|
|
12
|
+
.map((name) => ADAPTER_PACKAGE.exec(name)?.[1])
|
|
13
|
+
.filter((name) => name !== undefined);
|
|
14
|
+
}
|
|
15
|
+
async function read(path) {
|
|
16
|
+
try {
|
|
17
|
+
return JSON.parse(await readFile(path, 'utf8'));
|
|
18
|
+
}
|
|
19
|
+
catch {
|
|
20
|
+
// No manifest, or one that is not JSON. Either way this cannot validate a name, and
|
|
21
|
+
// reporting every `adapters:` key as unknown would be worse than saying nothing.
|
|
22
|
+
return undefined;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=adapters.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"adapters.js","sourceRoot":"","sources":["../../src/scan/adapters.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,sEAAsE;AACtE,MAAM,eAAe,GAAG,0BAA0B,CAAC;AAEnD,6FAA6F;AAC7F,MAAM,CAAC,KAAK,UAAU,UAAU,CAAC,IAAY;IAC3C,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,cAAc,CAAC,CAAC,CAAC;IACxD,IAAI,CAAC,QAAQ;QAAE,OAAO,EAAE,CAAC;IAEzB,MAAM,QAAQ,GAAG,EAAE,GAAG,QAAQ,CAAC,YAAY,EAAE,GAAG,QAAQ,CAAC,eAAe,EAAE,CAAC;IAE3E,OAAO,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC;SACzB,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;SAC9C,MAAM,CAAC,CAAC,IAAI,EAAkB,EAAE,CAAC,IAAI,KAAK,SAAS,CAAC,CAAC;AAC1D,CAAC;AAED,KAAK,UAAU,IAAI,CAAC,IAAY;IAC9B,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,KAAK,CAAC,MAAM,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,CAAa,CAAC;IAC9D,CAAC;IAAC,MAAM,CAAC;QACP,oFAAoF;QACpF,iFAAiF;QACjF,OAAO,SAAS,CAAC;IACnB,CAAC;AACH,CAAC"}
|
package/dist/scan/bundling.d.ts
CHANGED
|
@@ -1,14 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* What a Fougere boot loads at RUNTIME, so a bundler must leave it alone.
|
|
3
|
-
*
|
|
4
|
-
* Stated once because it was stated twice and the two had already drifted: the Vite plugin
|
|
5
|
-
* listed `@fougere/schema`, `@fougere/adapter-graphql` and `@fougere/auth-better`, the Next
|
|
6
|
-
* one did not, and BOTH omitted the two packages `@fougere/app`'s boot actually imports
|
|
7
|
-
* dynamically — `@fougere/defaults` and `@fougere/transport-http`. A list a bundler reads
|
|
8
|
-
* has no way to notice it is wrong: nothing fails at build time, the app fails at boot.
|
|
9
|
-
*
|
|
10
|
-
* It sits here rather than beside the dynamic imports because both readers are BUILD-TIME
|
|
11
|
-
* plugins that already depend on core, and neither may pull the boot into a bundler config.
|
|
12
|
-
*/
|
|
1
|
+
/** What a Fougere boot loads at RUNTIME, so a bundler must leave it alone. */
|
|
13
2
|
export declare const RUNTIME_PACKAGES: readonly string[];
|
|
14
3
|
//# sourceMappingURL=bundling.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bundling.d.ts","sourceRoot":"","sources":["../../src/scan/bundling.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"bundling.d.ts","sourceRoot":"","sources":["../../src/scan/bundling.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,eAAO,MAAM,gBAAgB,EAAE,SAAS,MAAM,EAY7C,CAAC"}
|
package/dist/scan/bundling.js
CHANGED
|
@@ -1,15 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* What a Fougere boot loads at RUNTIME, so a bundler must leave it alone.
|
|
3
|
-
*
|
|
4
|
-
* Stated once because it was stated twice and the two had already drifted: the Vite plugin
|
|
5
|
-
* listed `@fougere/schema`, `@fougere/adapter-graphql` and `@fougere/auth-better`, the Next
|
|
6
|
-
* one did not, and BOTH omitted the two packages `@fougere/app`'s boot actually imports
|
|
7
|
-
* dynamically — `@fougere/defaults` and `@fougere/transport-http`. A list a bundler reads
|
|
8
|
-
* has no way to notice it is wrong: nothing fails at build time, the app fails at boot.
|
|
9
|
-
*
|
|
10
|
-
* It sits here rather than beside the dynamic imports because both readers are BUILD-TIME
|
|
11
|
-
* plugins that already depend on core, and neither may pull the boot into a bundler config.
|
|
12
|
-
*/
|
|
1
|
+
/** What a Fougere boot loads at RUNTIME, so a bundler must leave it alone. */
|
|
13
2
|
export const RUNTIME_PACKAGES = [
|
|
14
3
|
'@fougere/app',
|
|
15
4
|
'@fougere/core',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bundling.js","sourceRoot":"","sources":["../../src/scan/bundling.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"bundling.js","sourceRoot":"","sources":["../../src/scan/bundling.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,MAAM,CAAC,MAAM,gBAAgB,GAAsB;IACjD,cAAc;IACd,eAAe;IACf,iBAAiB;IACjB,mBAAmB;IACnB,yBAAyB;IACzB,sBAAsB;IACtB,0BAA0B;IAC1B,sBAAsB;IACtB,gBAAgB;IAChB,MAAM;IACN,YAAY;CACb,CAAC"}
|
|
@@ -1,18 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The names the scan READS instead of deriving them.
|
|
3
|
-
*
|
|
4
|
-
* Everything else a frond states, it states by its shape; these seven directories and the
|
|
5
|
-
* import prefix are the one place where a name is the declaration. They were spelled as
|
|
6
|
-
* literals in five packages, so a project could not move any of them and `frondsDir` was
|
|
7
|
-
* a declared key with no reader.
|
|
8
|
-
*/
|
|
1
|
+
/** The names the scan READS instead of deriving them. */
|
|
9
2
|
export interface Conventions {
|
|
10
|
-
/**
|
|
11
|
-
* The scope a frond's package name carries — `@fronds/blog`.
|
|
12
|
-
*
|
|
13
|
-
* A real package name, not only an alias: the CLI writes it as `name` in a scaffolded
|
|
14
|
-
* frond and as a `workspace:*` dependency in the app that consumes it.
|
|
15
|
-
*/
|
|
3
|
+
/** The scope a frond's package name carries — `@fronds/blog`. */
|
|
16
4
|
scope: string;
|
|
17
5
|
/** The directory holding fronds, below the project root. */
|
|
18
6
|
fronds: string;
|
|
@@ -29,12 +17,7 @@ export interface Conventions {
|
|
|
29
17
|
versions: string;
|
|
30
18
|
};
|
|
31
19
|
}
|
|
32
|
-
/**
|
|
33
|
-
* What a project means when it declares nothing — the convention itself.
|
|
34
|
-
*
|
|
35
|
-
* `@fronds` and not `@frond`: the npm org for the singular belongs to someone else, and a
|
|
36
|
-
* scope is a name that must be ownable.
|
|
37
|
-
*/
|
|
20
|
+
/** What a project means when it declares nothing — the convention itself. */
|
|
38
21
|
export declare const DEFAULT_CONVENTIONS: Conventions;
|
|
39
22
|
/** What a `fougere.config.ts` may state: only the names that differ. */
|
|
40
23
|
export type ConventionsInput = {
|
|
@@ -42,29 +25,12 @@ export type ConventionsInput = {
|
|
|
42
25
|
fronds?: string;
|
|
43
26
|
dirs?: Partial<Conventions['dirs']>;
|
|
44
27
|
};
|
|
45
|
-
/**
|
|
46
|
-
* The convention, with a project's exceptions folded in.
|
|
47
|
-
*
|
|
48
|
-
* Merged one level into `dirs` so renaming one directory does not require restating the
|
|
49
|
-
* other six — the same reading `sources:` and `ports:` get, where only the exception is
|
|
50
|
-
* declared.
|
|
51
|
-
*/
|
|
28
|
+
/** The convention, with a project's exceptions folded in. */
|
|
52
29
|
export declare function resolveConventions(input?: ConventionsInput): Conventions;
|
|
53
30
|
/** The package name a frond answers to. */
|
|
54
31
|
export declare function frondPackage(name: string, conventions: Conventions): string;
|
|
55
|
-
/**
|
|
56
|
-
* Directories whose classes register as providers — two spellings, one behaviour.
|
|
57
|
-
*
|
|
58
|
-
* A project may point both roles at one directory; the scan must then read it once, or
|
|
59
|
-
* every provider would be registered twice.
|
|
60
|
-
*/
|
|
32
|
+
/** Directories whose classes register as providers — two spellings, one behaviour. */
|
|
61
33
|
export declare function providerDirsOf(conventions: Conventions): string[];
|
|
62
|
-
/**
|
|
63
|
-
* The frond vocabulary — every directory the scan reads.
|
|
64
|
-
*
|
|
65
|
-
* What a reader needs to bound a frond: the Nuxt module watches these for the root frond
|
|
66
|
-
* (watching the root itself would match every write), and a flat app's tsconfig lists
|
|
67
|
-
* them instead of `["."]`, which would swallow `app/` and `nuxt.config.ts`.
|
|
68
|
-
*/
|
|
34
|
+
/** The frond vocabulary — every directory the scan reads. */
|
|
69
35
|
export declare function frondDirsOf(conventions: Conventions): string[];
|
|
70
36
|
//# sourceMappingURL=conventions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conventions.d.ts","sourceRoot":"","sources":["../../src/scan/conventions.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"conventions.d.ts","sourceRoot":"","sources":["../../src/scan/conventions.ts"],"names":[],"mappings":"AAAA,yDAAyD;AAEzD,MAAM,WAAW,WAAW;IAC1B,iEAAiE;IACjE,KAAK,EAAE,MAAM,CAAC;IACd,4DAA4D;IAC5D,MAAM,EAAE,MAAM,CAAC;IACf,8EAA8E;IAC9E,IAAI,EAAE;QACJ,QAAQ,EAAE,MAAM,CAAC;QACjB,QAAQ,EAAE,MAAM,CAAC;QACjB,QAAQ,EAAE,MAAM,CAAC;QACjB,YAAY,EAAE,MAAM,CAAC;QACrB,UAAU,EAAE,MAAM,CAAC;QACnB,UAAU,EAAE,MAAM,CAAC;QACnB,KAAK,EAAE,MAAM,CAAC;QACd,uFAAuF;QACvF,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH;AAED,6EAA6E;AAC7E,eAAO,MAAM,mBAAmB,EAAE,WAajC,CAAC;AAEF,wEAAwE;AACxE,MAAM,MAAM,gBAAgB,GAAG;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,CAAC;CACrC,CAAC;AAEF,6DAA6D;AAC7D,wBAAgB,kBAAkB,CAAC,KAAK,CAAC,EAAE,gBAAgB,GAAG,WAAW,CAMxE;AAED,2CAA2C;AAC3C,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,WAAW,GAAG,MAAM,CAE3E;AAED,sFAAsF;AACtF,wBAAgB,cAAc,CAAC,WAAW,EAAE,WAAW,GAAG,MAAM,EAAE,CAEjE;AAED,6DAA6D;AAC7D,wBAAgB,WAAW,CAAC,WAAW,EAAE,WAAW,GAAG,MAAM,EAAE,CAK9D"}
|
package/dist/scan/conventions.js
CHANGED
|
@@ -1,17 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
|
|
3
|
-
*
|
|
4
|
-
* Everything else a frond states, it states by its shape; these seven directories and the
|
|
5
|
-
* import prefix are the one place where a name is the declaration. They were spelled as
|
|
6
|
-
* literals in five packages, so a project could not move any of them and `frondsDir` was
|
|
7
|
-
* a declared key with no reader.
|
|
8
|
-
*/
|
|
9
|
-
/**
|
|
10
|
-
* What a project means when it declares nothing — the convention itself.
|
|
11
|
-
*
|
|
12
|
-
* `@fronds` and not `@frond`: the npm org for the singular belongs to someone else, and a
|
|
13
|
-
* scope is a name that must be ownable.
|
|
14
|
-
*/
|
|
1
|
+
/** The names the scan READS instead of deriving them. */
|
|
2
|
+
/** What a project means when it declares nothing — the convention itself. */
|
|
15
3
|
export const DEFAULT_CONVENTIONS = {
|
|
16
4
|
scope: '@fronds',
|
|
17
5
|
fronds: 'fronds',
|
|
@@ -26,13 +14,7 @@ export const DEFAULT_CONVENTIONS = {
|
|
|
26
14
|
versions: 'versions',
|
|
27
15
|
},
|
|
28
16
|
};
|
|
29
|
-
/**
|
|
30
|
-
* The convention, with a project's exceptions folded in.
|
|
31
|
-
*
|
|
32
|
-
* Merged one level into `dirs` so renaming one directory does not require restating the
|
|
33
|
-
* other six — the same reading `sources:` and `ports:` get, where only the exception is
|
|
34
|
-
* declared.
|
|
35
|
-
*/
|
|
17
|
+
/** The convention, with a project's exceptions folded in. */
|
|
36
18
|
export function resolveConventions(input) {
|
|
37
19
|
return {
|
|
38
20
|
scope: input?.scope ?? DEFAULT_CONVENTIONS.scope,
|
|
@@ -44,22 +26,11 @@ export function resolveConventions(input) {
|
|
|
44
26
|
export function frondPackage(name, conventions) {
|
|
45
27
|
return `${conventions.scope}/${name}`;
|
|
46
28
|
}
|
|
47
|
-
/**
|
|
48
|
-
* Directories whose classes register as providers — two spellings, one behaviour.
|
|
49
|
-
*
|
|
50
|
-
* A project may point both roles at one directory; the scan must then read it once, or
|
|
51
|
-
* every provider would be registered twice.
|
|
52
|
-
*/
|
|
29
|
+
/** Directories whose classes register as providers — two spellings, one behaviour. */
|
|
53
30
|
export function providerDirsOf(conventions) {
|
|
54
31
|
return [...new Set([conventions.dirs.services, conventions.dirs.repositories])];
|
|
55
32
|
}
|
|
56
|
-
/**
|
|
57
|
-
* The frond vocabulary — every directory the scan reads.
|
|
58
|
-
*
|
|
59
|
-
* What a reader needs to bound a frond: the Nuxt module watches these for the root frond
|
|
60
|
-
* (watching the root itself would match every write), and a flat app's tsconfig lists
|
|
61
|
-
* them instead of `["."]`, which would swallow `app/` and `nuxt.config.ts`.
|
|
62
|
-
*/
|
|
33
|
+
/** The frond vocabulary — every directory the scan reads. */
|
|
63
34
|
export function frondDirsOf(conventions) {
|
|
64
35
|
const { entities, handlers, presenters, collectors, seeds, versions } = conventions.dirs;
|
|
65
36
|
return [...new Set([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conventions.js","sourceRoot":"","sources":["../../src/scan/conventions.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"conventions.js","sourceRoot":"","sources":["../../src/scan/conventions.ts"],"names":[],"mappings":"AAAA,yDAAyD;AAqBzD,6EAA6E;AAC7E,MAAM,CAAC,MAAM,mBAAmB,GAAgB;IAC9C,KAAK,EAAE,SAAS;IAChB,MAAM,EAAE,QAAQ;IAChB,IAAI,EAAE;QACJ,QAAQ,EAAE,UAAU;QACpB,QAAQ,EAAE,UAAU;QACpB,QAAQ,EAAE,UAAU;QACpB,YAAY,EAAE,cAAc;Q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|
6
6
|
core?: string;
|
|
7
7
|
}
|
|
8
|
-
/**
|
|
9
|
-
* Write a scan down. The result is a TypeScript module whose only imports are the classes
|
|
10
|
-
* the scan found — static, so a bundler traces them — and whose only value is the
|
|
11
|
-
* descriptor `createApp` asks for.
|
|
12
|
-
*/
|
|
8
|
+
/** Write a scan down. */
|
|
13
9
|
export declare function emitScan(result: ScanResult, options: EmitOptions): string;
|
|
14
10
|
//# sourceMappingURL=emit.d.ts.map
|
package/dist/scan/emit.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emit.d.ts","sourceRoot":"","sources":["../../src/scan/emit.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"emit.d.ts","sourceRoot":"","sources":["../../src/scan/emit.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAG9C,MAAM,WAAW,WAAW;IAC1B,+EAA+E;IAC/E,OAAO,EAAE,MAAM,CAAC;IAChB,4EAA4E;IAC5E,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AA0ID,yBAAyB;AACzB,wBAAgB,QAAQ,CAAC,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,WAAW,GAAG,MAAM,CA2CzE"}
|
package/dist/scan/emit.js
CHANGED
|
@@ -1,31 +1,9 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The scan, written down as a module — what `createApp` is handed where there is no disk.
|
|
3
|
-
*
|
|
4
|
-
* It RE-RESOLVES NOTHING. By the time this runs the scan has already decided what every
|
|
5
|
-
* slot holds, and `resolveSchema` put the entity's own class in `contract.output` — the
|
|
6
|
-
* very object `EntityEntry.entityClass` holds. So the emitter keeps a table from object
|
|
7
|
-
* to import alias and writes the alias. Identity is preserved because it is the same
|
|
8
|
-
* object that becomes the same import, which is what three call sites depend on
|
|
9
|
-
* (`adapter/graphql`'s `view === entity.entityClass` and its WeakMap, and `bootstrap`'s
|
|
10
|
-
* `outputSchema !== entity.entityClass`). An emitter that re-resolved instead would build
|
|
11
|
-
* a second class for `Post` and those three would silently take the other branch.
|
|
12
|
-
*
|
|
13
|
-
* Measured on three real projects: every live reference is either a class the descriptor
|
|
14
|
-
* already names by `filePath`, a named export of the file that declared the signature, or
|
|
15
|
-
* `Partial<X>` — the one derivation `resolveSchema` fabricates.
|
|
16
|
-
*/
|
|
1
|
+
/** The scan, written down as a module — what `createApp` is handed where there is no disk. */
|
|
17
2
|
import { dirname, relative } from 'node:path';
|
|
18
3
|
import { ANONYMOUS_SCHEMA_NAME, Card } from '@fougere/schema';
|
|
19
4
|
/** Is a TypeScript compiler going to read this module? Its name is the only thing that says. */
|
|
20
5
|
const isTypeScript = (outFile) => /\.tsx?$/.test(outFile);
|
|
21
|
-
/**
|
|
22
|
-
* A source file becomes a specifier its reader can follow — and the two readers differ.
|
|
23
|
-
*
|
|
24
|
-
* A `.ts` destination is compiled by tsc under Node16 resolution, which spells a
|
|
25
|
-
* TypeScript source with `.js`. A `.mjs` destination is read by a bundler, which resolves
|
|
26
|
-
* the path AS IT IS ON DISK — measured, Nitro's rollup refused `Post.seed.js` because no
|
|
27
|
-
* such file exists. One rule, read off the destination, exactly like the type annotation.
|
|
28
|
-
*/
|
|
6
|
+
/** A source file becomes a specifier its reader can follow — and the two readers differ. */
|
|
29
7
|
function specifierOf(filePath, outFile) {
|
|
30
8
|
const path = relative(dirname(outFile), filePath);
|
|
31
9
|
const rel = isTypeScript(outFile) ? path.replace(/\.tsx?$/, '.js') : path;
|
|
@@ -65,15 +43,7 @@ class Imports {
|
|
|
65
43
|
aliasOf(value) { return this.byValue.get(value); }
|
|
66
44
|
render() { return this.lines.join('\n'); }
|
|
67
45
|
}
|
|
68
|
-
/**
|
|
69
|
-
* What a schema slot becomes in the generated module.
|
|
70
|
-
*
|
|
71
|
-
* Three answers, and the third is the only rule: a class already imported is its alias; a
|
|
72
|
-
* named export of the file that declared the signature is imported by its own name — it
|
|
73
|
-
* IS exported there, because that is where `resolveSchema` found it; and an anonymous
|
|
74
|
-
* schema is `Partial<X>`, the one derivation `resolveSchema` builds, so it is written as
|
|
75
|
-
* the derivation rather than as a value.
|
|
76
|
-
*/
|
|
46
|
+
/** What a schema slot becomes in the generated module. */
|
|
77
47
|
function schemaRef(schema, declaredIn, imports) {
|
|
78
48
|
if (!schema)
|
|
79
49
|
return undefined;
|
|
@@ -157,11 +127,7 @@ function frondOf(f, imports) {
|
|
|
157
127
|
' }',
|
|
158
128
|
].filter(Boolean).join('\n');
|
|
159
129
|
}
|
|
160
|
-
/**
|
|
161
|
-
* Write a scan down. The result is a TypeScript module whose only imports are the classes
|
|
162
|
-
* the scan found — static, so a bundler traces them — and whose only value is the
|
|
163
|
-
* descriptor `createApp` asks for.
|
|
164
|
-
*/
|
|
130
|
+
/** Write a scan down. */
|
|
165
131
|
export function emitScan(result, options) {
|
|
166
132
|
const imports = new Imports(options.outFile);
|
|
167
133
|
const core = options.core ?? '@fougere/core';
|
package/dist/scan/emit.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emit.js","sourceRoot":"","sources":["../../src/scan/emit.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"emit.js","sourceRoot":"","sources":["../../src/scan/emit.ts"],"names":[],"mappings":"AAAA,8FAA8F;AAC9F,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAC9C,OAAO,EAAE,qBAAqB,EAAE,IAAI,EAAmB,MAAM,iBAAiB,CAAC;AAc/E,gGAAgG;AAChG,MAAM,YAAY,GAAG,CAAC,OAAe,EAAW,EAAE,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;AAE3E,4FAA4F;AAC5F,SAAS,WAAW,CAAC,QAAgB,EAAE,OAAe;IACpD,MAAM,IAAI,GAAG,QAAQ,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,QAAQ,CAAC,CAAC;IAClD,MAAM,GAAG,GAAG,Y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