This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-11-16
Channels
- # adventofcode (1)
- # announcements (16)
- # babashka (7)
- # beginners (77)
- # calva (31)
- # cider (18)
- # clj-commons (16)
- # cljfx (5)
- # clojars (5)
- # clojure (33)
- # clojure-europe (15)
- # clojure-nl (1)
- # clojure-norway (15)
- # clojure-uk (4)
- # clojurescript (1)
- # conjure (1)
- # core-logic (7)
- # cursive (16)
- # data-science (4)
- # datalevin (6)
- # emacs (20)
- # events (5)
- # fulcro (15)
- # holy-lambda (1)
- # introduce-yourself (1)
- # jobs (2)
- # lsp (30)
- # luminus (3)
- # malli (3)
- # membrane-term (19)
- # missionary (62)
- # off-topic (39)
- # pathom (24)
- # polylith (5)
- # portal (9)
- # practicalli (3)
- # re-frame (16)
- # reagent (5)
- # remote-jobs (1)
- # reveal (21)
- # rewrite-clj (8)
- # shadow-cljs (13)
- # spacemacs (23)
- # sql (12)
- # timbre (2)
- # tools-deps (1)
- # xtdb (4)
Managed to embed portal in emacs!
(require '[portal.runtime.shell :as shell]
'[portal.api :as portal]
'[portal.runtime.browser :as browser])
(defmethod browser/-open :emacs/xwidget [{:keys [portal options server]}]
(let [url (pr-str (str "http://" (:host server) ":" (:port server) "?" (:session-id portal)))]
(shell/sh "emacsclient" "-e" (str "(xwidget-webkit-browse-url" url ")"))))
(portal/open {:launcher :emacs/xwidget})
This is awesome! I do get *ERROR*: Your Emacs was not compiled with xwidgets support
when I try this launcher. I wonder if brew has a build of emacs with xwidgets :thinking_face:
While it does work, the user experience around it is meh/10, so I wouldn't add it until that was figured out, unless you'd like me to PR it as an experimental extension
I'll see if I can get it working. If the meh experience is due to performance, that might be able to improve. And improving perf would make it better in all other browsers.
I don't think it's performance, you'll probably try it yourself later today and see
If anyone has ideas on how portal interactions could be used to generate code and would like to share, please comment on this https://github.com/djblue/portal/issues/77.