Comments (14)
Unfortunately, I have no time to provide any ready to use solutions. It is just a Proof-Of-Concept solution that you should adopt to your needs and not a framework at all.
from electron-java-app.
Which is totally understandable! Would you accept pull requests that make it easier to include custom jars (I was thinking about an additional script parameter and a concerning tweak for the readme)?
from electron-java-app.
Including custom JARs is available right now, just add necessary dependencies in build.gradle file. In case of Spring Boot - you have to start an additional servlet in org/strangeway/electronvaadin/Launcher.java to be able to work with it or integrate it somehow into Vaadin application. Please note, that this demo uses Vaadin as UI and it cannot be changed, since it is the main idea of the sample - use Java only for the entire application.
from electron-java-app.
I'm interested in any generic ideas / pull requests that can help developers to build apps using this stack.
from electron-java-app.
Please note, that this demo uses Vaadin as UI and it cannot be changed, since it is the main idea of the sample - use Java only for the entire application.
I'm aware of that 🙂.
Including custom JARs is available right now, just add necessary dependencies in build.gradle file. In case of Spring Boot - you have to start an additional servlet in org/strangeway/electronvaadin/Launcher.java to be able to work with it or integrate it somehow into Vaadin application.
Just to make things more clear, I am talking about a Vaadin Springboot application.
My goal is that I add the built jar to a specific directory and then build the electron application via a script which then outputs the executable.
This probably requires me to add beforehand some extra dependencies since you seem to do some interprocess communication via JS right?
Another question of mine, I found that you didn't add any license to this repo, in my country if i'm correctly informed this forbids me even to download your repository? Or evenmore so any commercial use of your code. Is this intended by you 😅?
from electron-java-app.
As of the license - it is the same as other stuff of CUBA Platform team on the Github - Apache License 2.0. I've just added the LICENSE file to the repo. If you provide Vaadin SpringBoot integration it would be great, just do not bring any specifics of your application and usage, use generic approaches. If you are planning to add custom jars from files then it is not interesting approach for others. Just fork the repo and create your application.
In fact - this repo is not a library/framework, it does not have any APIs, so anything can be changed dramatically in the future.
from electron-java-app.
Thank you for adding the license I will try my best, and I will keep in mind to only use generic approaches 😉.
from electron-java-app.
If you are interested you can checkout my fork it is already working.
Do you have some ideas what could be improved?
from electron-java-app.
Hi, I've checked your improvements. I do not want to merge them here, because they are relevant only for those who do not use Vaadin for UI. I'd rather implement Spring integration with Vaadin-Spring Add-on: https://vaadin.com/directory/component/vaadin-spring , see #11
Also, I see that you propose to add jars as files, this is a strange approach. It would be better if we can add jars as Maven dependencies. Anyway, it is not the case for this demo repository. I propose to extract JS launcher to a separate project if you want to use it for Spring Boot applications with custom front-end. There is no need to add Vaadin dependencies for such projects, but instead, we can provide Spring Boot template application.
from electron-java-app.
Hi, I've checked your improvements. I do not want to merge them here, because they are relevant only for those who do not use Vaadin for UI. I'd rather implement Spring integration with Vaadin-Spring Add-on: https://vaadin.com/directory/component/vaadin-spring , see #11
Also, I see that you propose to add jars as files, this is a strange approach. It would be better if we can add jars as Maven dependencies. Anyway, it is not the case for this demo repository. I propose to extract JS launcher to a separate project if you want to use it for Spring Boot applications with custom front-end. There is no need to add Vaadin dependencies for such projects, but instead, we can provide Spring Boot template application.
First of all if you don't want to merge the new approach thats fine. By reading your comment I got the feeling you might have misunderstood the alternative approach so just to recap:
The new approach is for users who have a slightly different use case than the current one.
If the user wants to ship his ready programmed application as an executable (no matter what framework he is actually using [I tested it with a Vaadin UI]) without adding any code to his application. He can simply built his Vaadin application (with f.e. SpringBoot) externally with the Buildtool of his choice as jar and drop it in the jar folder and run the build script. This will output an Electron Application which starts his jar file and then call a specific url.
If the user requires to actually communicate with the electron framework which is in your solution the case the user needs to add code to his application.
So the difference is that the user does not need to add code to his existing application but is still able to wrap it in electron which I personally find quite nice. Also it allows Users who built their Webapp with another framework to use the library (but this was only a side effect) my primary goal was to make it simpler for a user with a different use case.
Edit:
There is the possibility that I keep this as a fork for users who have the same use case as I do.
from electron-java-app.
In this case, lets build something like electron-vaadin-wrapper that will contain only code that is required for wrapping an application. That will be really useful for existing applications. But I'd like to keep this demo as a separate PoC on the approach rather than ready to use tool/framework. You can develop your fork in parallel or even rename (if you want) it to fill the niche of electron-runner for java apps. Actually, your approach does not require java source at all, so I recommend that you remove them completely from the project.
My concern is only for purpose of these two approaches. It seems, they should be implemented in separate projects / separate starters.
from electron-java-app.
Besides, thank you for joining me in this direction of the application development. I'm glad that this topic is relevant for someone else.
from electron-java-app.
In this case, lets build something like electron-vaadin-wrapper that will contain only code that is required for wrapping an application. That will be really useful for existing applications. But I'd like to keep this demo as a separate PoC on the approach rather than ready to use tool/framework. You can develop your fork in parallel or even rename (if you want) it to fill the niche of electron-runner for java apps.
Sounds like a good idea. I also think that it is better to fork it and keep it separate.
Actually, your approach does not require java source at all, so I recommend that you remove them completely from the project.
I will do so 😉.
Besides, thank you for joining me in this direction of the application development. I'm glad that this topic is relevant for someone else.
You are welcome!
from electron-java-app.
hey guys, thanks for both your work in this direction. I was looking for something like this for a side project
from electron-java-app.
Related Issues (20)
- Use Vaadin-Spring integration
- Is it possible to build standard reactjs apps with this kind of setup? HOT 1
- Does not build with Node 10+ and no title bar
- Where to set encoding to UTF-8 for Upload Field. HOT 1
- Migrate to Vaadin Flow
- bundleApp Task result cannot be launched by double click in finder
- Generate Java API for Electron
- Provide Application template
- Generate DOM API for Java
- Embed Java process to Node
- Integrate JSweet
- Release Gradle plugin
- main.js serverProcess launch
- Build minimal JRE image with jlink
- Development in the IDE HOT 4
- Please help me. I can't run the application. Gradle runApp HOT 1
- Classpath too long in electron-vaadin.bat
- M1 Mac Could not find org.nodejs:node:12.14.1
- How to ensure that WebSocket is not accessed illegally? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from electron-java-app.