LLRT (Low Latency Runtime) is an experimental, lightweight JavaScript runtime designed to address the growing demand for fast and efficient Serverless applications.
Apache License 2.0
7.76k
stars
342
forks
source link
fix: [ERROR] No replacement found for "getRuntimeConfig" #282
// Error during bundling because getRuntimeConfig is not included in the code.
export const ClientSharedValues = {
lstatSync: () => { },
};
This PR allows for runtimeConfig.shared.js that do not follow the laws to be bundled as is, without making an error that the wrapper logic cannot be injected.
Checklist
[ ] Created unit tests in tests/unit and/or in Rust for my feature if needed
[x] Ran make fix to format JS and apply Clippy auto fixes
[x] Made sure my code didn't add any additional warnings: make check
[ ] Updated documentation if needed (API.md/README.md/Other)
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Description of changes
Detail
There is wrapper logic in
build.mjs
that injects AWS credentials and region parameters intoruntimeConfig.shared.js
in@aws-sdk
.However, we found that there are
runtimeConfig.shared.js
in@aws-sdk
that do not follow the following rules.@aws-sdk/client-s3/dist-es/runtimeConfig.shared.js:
For example,
@aws-sdk/lib-storage
(which I hope to bundle in the future)@aws-sdk/lib-storage/dist-es/runtimeConfig.shared.js:
This PR allows for
runtimeConfig.shared.js
that do not follow the laws to be bundled as is, without making an error that the wrapper logic cannot be injected.Checklist
tests/unit
and/or in Rust for my feature if neededmake fix
to format JS and apply Clippy auto fixesmake check
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.