Swift bindings for the Chromium Embedded Framework.
Xcode 10.1, Swift 4.2 (see notes below)
Supported target platforms: macOS 10.9+, 10.10+, 10.11+ (currently x86_64 only)
Required tools: jq, xcpretty
To set up your environment:
$ brew install jq
$ gem install xcpretty
You can now build CEF.swift using Carthage. Just add the following line to your Cartfile
:
github "lvsti/CEF.swift" "<branch_specifier>"
(For the branch_specifier
, see the notes on branches below.)
Note that the bootstrap build will take quite some time as CEF.swift has to fetch and build external dependencies as well.
scripts/setup.sh
from the repo rootCEF is developed on multiple branches simultaneously, which differ in API and functionality (see Spotify OpenSource and ChromeStatus). CEF.swift aims at supporting the current stable release branch and a couple more of earlier releases. For any CEF branch NNNN
, the corresponding CEF.swift branch is named cef_NNNN
.
Currently supported branches:
Archived branches (not maintained anymore):
Check out the (pretty skinny) CEFDemo app under Samples/CEFDemo
to get the basic idea of how a CEF-based app should look like. For more inspiration, take a look at the cefsimple
and cefclient
apps shipped with the CEF binary distribution.
CEF.swift is just a (partial) language wrapper around CEF. Once you can get a webpage to load, you are pretty much set on the integration side. If, later on, you bump into a problem, you should first go and check the official CEF forum for guidance unless it is clearly a flaw in the Swift bindings themselves (in which case please create an issue here).
This project is incomplete, untested, and most likely unstable, so use it at your own risk. Bug reports and suggestions are welcome though.