Coder Social home page Coder Social logo

humbleui's Introduction

“When you design a new user interface, you have to start off humbly”

— Steve Jobs presenting Aqua

Humble UI is a desktop UI framework for Clojure. No Electron. No JavaScript. Only JVM and native code.

Goal

  • A way to build high-quality desktop UIs
  • Build better apps that’s possible with web now, while staying cross-platform
  • Build them faster in Clojure

Motivation

  • Create desktop apps in Clojure
  • Electron is a great landmark
    • People prefer native apps to web apps
      • Normal shortcuts, icon, its own window, file system access, notifications, OS integrations
    • Developing real native apps is expensive
    • JavaScript + Chrome have huge overhead, can be slow
  • Java has “UI curse”
    • Previous attempts were cumbersome for user
    • Mimicking native look and feel didn’t work
    • Looked bad
  • Time of declarative UIs is now
    • React
    • Flutter
    • SwiftUI
    • Jetpack Compose
  • Web + Electron cleared the way for non-native look and feel
    • Write once, run everywhere is no longer rejected by users
    • Even native apps have many custom UI elements
  • Flutter proved new UI stack is a feasible task
  • Clojure is the best language for UI development
    • Performant enough to not noticeably lag
    • Access to full power of your computer (multithreaded)
    • REPL + interactive development == instant feedback loop
    • Proven itself great in CLJS world, can do the same on desktop

How is it going to be different

  • No goal to look native, aim for web look (write once, run everywhere)
  • Embrace platform differences in OS integration
  • Declarative UI API is much more pleasant to work with (+plays well with FP)
  • Expose low-level APIs along with high-level API
    • People can solve non-trivial problems in their own way, without hacks
  • Superpowers of Clojure

Architecture

  • Leverage Skia via Skija for high-performance GPU-accelerated graphics
  • JWM (Java Window Manager) for OS integration (simple, common ground, embrace the differences)

Status

Work in progress. No docs, and everything changes every day.

Resources

Slack:

Posts:

Videos:

Sample apps:

Development

Run REPL server:

./script/repl.py

To reload demo app using tools.namespace, evaluate:

(user/reload)

Examples

(require '[io.github.humbleui.ui :as ui])

(def ui
  (ui/default-theme {}
    (ui/center
      (ui/label "Hello from Humble UI! 👋"))))

(ui/start-app!
  (ui/window
    {:title "Humble 🐝 UI"}
    #'ui))

humbleui's People

Contributors

tonsky avatar folcon avatar oakmac avatar pangloss avatar trueneu avatar alexander-panin avatar the-alchemist avatar frenchy64 avatar igorhub avatar jelmerderonde avatar jerems avatar quezion avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.