Skip to content
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

Issue with react server side script JS #567

Closed
kdesineedi opened this issue Sep 26, 2021 · 4 comments
Closed

Issue with react server side script JS #567

kdesineedi opened this issue Sep 26, 2021 · 4 comments

Comments

@kdesineedi
Copy link

Hi all,

I am using the below version of J2V8.If I load a simple javascript things work fine however if I use a much larger file for server side rendering, the java code terminates without throwing any error at the V8.executeScript())

              <dependency>
			<groupId>com.eclipsesource.j2v8</groupId>
			<artifactId>j2v8_win32_x86_64</artifactId>
			<version>2.2.1</version>
		</dependency>

Can you please let me know what the issue could be or how to debug this as there is no error message thrown.

@caoccao
Copy link

caoccao commented Sep 27, 2021

The latest Windows build v4.6.0 was released in 2016 and there seems to have been no official support for many years. Please refer to Reduce the scope of the J2V8 project for detail.

For server side rendering, e.g. reactjs, I recommend Javet.

@kdesineedi
Copy link
Author

Thanks @caoccao .Could you please share any example on how you are loading a react server side rendering script using Javet, evaluate it and then use it for invoking functions within that script?

I tried to go through the Javet documentation but could not find one. Apologies if I missed it but please guide?

@caoccao
Copy link

caoccao commented Sep 27, 2021

Thanks @caoccao .Could you please share any example on how you are loading a react server side rendering script using Javet, evaluate it and then use it for invoking functions within that script?

I tried to go through the Javet documentation but could not find one. Apologies if I missed it but please guide?

It has a genuine Node.js embedded. So, you just do what you normally do in the embedded Node.js. You may start with the simple tutorial.

@kdesineedi
Copy link
Author

Awesome.Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants