Headless-Browser
A headless browser written in Java.
HBrowser hBrowser = new HBrowser();
HWindow hWindow = hBrowser.openNewWindow().load("https://wikipedia.org");
TL;DR
- Can load pages and partially execute their JavaScript code.
- Contributions are needed for implementing all JS Web-APIs, to achieve full JavaScript support.
- Click here to see a list of already implemented APIs and how to implement one on your own.
Why contribute?
I tried multiple different things like JCEF, Pandomium, Selenium, Selenium based Maven dependencies like JWebdriver, HtmlUnit and maybe some more I don't remember now, but all have one thing in common. They have some kind of very nasty caveat.
That's why this project exists, to create a completely new browser, not dependent on Chromium or Waterfox or whatever, written in Java, compatible with all operating systems that can run Java. We use Jsoup to handle HTML and the GraalJS engine to handle JavaScript.
Now you may ask: Why do you need my help? Our problem is that most of the JavaScript code out there uses so called Web-APIs , which get shipped with each browser. Every browser implements them differently , but they are more or less the same accross all browsers. Since this projects aim is to create a new browser written in Java, completly independent from Chromium, we will need to implement those APIs by ourselfs.
There are a lot of Web-APIs available, so we need a lot of people to implement them. If you want to help us, thank you very much, already in advance! Click here to see a list of already implemented APIs and how to implement one on your own. If you are working on an implementation open an issue to keep track of who is working on what and avoid duplicate work.
Installation
- Java 8 or higher required.
- Click here for maven/gradle/sbt/leinigen instructions.
- Make sure to watch this repository to get notified of future updates.
Features
- Free & Open-Source
- Uses Jsoup for editing HTML directly in Java.
- Uses the blazing fast GraalJS-Engine, which supports latest JavaScript code (with latest ECMA specifications).
- Access to all JS-Web APIs from within Java
- Has all, standard JavaScript Web-APIs implemented.
Contribute/Build
Beginners
If you have never contributed before, we recommend this Beginners Article. If you are planning to make big changes, create an issue first, where you explain what you want to do. Thank you in advance for every contribution! If you don't know how to import a GitHub project, check out this guide: IntelliJ IDEA Cloning Guide
Build-Details
- Written in Java, with JDK 8, inside of IntelliJ IDEA
- Built with Maven, profiles: clean package
Links
- https://spec.whatwg.org/ | Details about JS Web-APIs
- https://www.w3.org/TR/?tag=webapi | Details about JS Web-APIs
Examples
Insert_usage_examples_here
FAQ
Frequently_asked_questions_here