-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
React SSR (from book) not working anymore #49
Comments
The above was encountered when bundling with rollup, so I went ahead and used babel & webpack bundling to see if that would help. The same
|
You can downgrade your |
We can also support |
@tpmccallum Can you check the latest QuickJS update with PR #51 merged? It should fix the issues mentioned here. |
Hi @juntao and @L-jasmine
Unfortunately, it appears that the error still persists.
Please let me know if there is anything else I can provide to assist. |
Please note, the line number from the error var u = new aa.TextEncoder(); |
pls use |
and remove |
Thanks @L-jasmine These changes have been applied. Once updated we received the following new error. $ npm run dev:build-server
> my-new-app@0.1.0 dev:build-server
> rollup -c rollup.config.js
./server/index.js → server-build/index.js...
(!) Unresolved dependencies
https://rollupjs.org/guide/en/#warning-treating-module-as-external-dependency
stream (imported by stream?commonjs-external)
util (imported by util?commonjs-external) I went ahead and updated the external: [ 'std', 'wasi_net','wasi_http', 'stream', 'util'], The build was able to succeed without any error. This means that we can move on to the start server command. It seems to be throwing a new error, as shown below. $ npm run dev:start-server
> my-new-app@0.1.0 dev:start-server
> wasmedge --dir .:. --dir ./internal:{$/home/tpmccallum/wasmedge-quickjs/target/wasm32-wasi/release}/internal wasmedge_quickjs.wasm ./server-build/index.js
[2022-05-14 14:37:46.363] [error] Bind guest directory failed:44
ReferenceError: could not load module filename 'stream' |
try |
Thanks @L-jasmine |
I have created a new React App and am using the wasmedge quickjs docs to build another SSR demo.
When I run the App via WasmEdge like this.
I get the following error
The error is pointing to the following line in the machine generated index.js file that is located in the server-build dir
The text was updated successfully, but these errors were encountered: