cd /tmp/
git clone https://github.com/clojure-emacs/cider-nrepl
cd cider-nrepl
git fetch origin pull/540/head:CIDER-NREPL-019
git checkout CIDER-NREPL-019
lein deps
lein install
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Run with: | |
clj -R:repl script.clj | |
Then connect emacs with `cider-connect`. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This work nicely for node repl. | |
Files involved, contents see below. | |
1. deps.edn | |
2. dev/nrepl_server.clj | |
3. dev/user.clj | |
Start clojure | |
$ clojure -A:nrepl-server |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; ... | |
(defun cider--infer-ports (host ssh-hosts) | |
"Infer nREPL ports on HOST. | |
Return a list of elements of the form (directory port). SSH-HOSTS is a list | |
of remote SSH hosts." | |
(let ((localp (or (nrepl-local-host-p host) | |
(not (assoc-string host ssh-hosts))))) | |
(if localp | |
;; change dir: current file might be remote |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Note: | |
Due to React 16.x react-dom/index conditionally load actual | |
react-dom implementation based on NODE_ENV, | |
we have to set it to "production" to make it works. | |
Note: | |
For advanced build, we include cljsjs/react* (just) to make use | |
its provided externs. | |
Files involved: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require '[clojure.data.xml :as xml]) | |
;; `emit-str` | |
(xml/emit-str | |
(xml/sexp-as-element | |
[:Login | |
[:AgencyCode "agencycode"] | |
[:Username "XML_Agency"] | |
[:Password "Password@123"]])) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; -*- mode: emacs-lisp; lexical-binding: t -*- | |
;; This file is loaded by Spacemacs at startup. | |
;; It must be stored in your home directory. | |
(defun dotspacemacs/layers () | |
"Layer configuration: | |
This function should only modify configuration layer settings." | |
(setq-default | |
;; Base distribution to use. This is a layer contained in the directory | |
;; `+distribution'. For now available distributions are `spacemacs-base' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; https://reactrouter.com/web/example/auth-workflow | |
;; ported to cljs with rumext | |
;; 28-Sep-2021 | |
;; Ridho | |
(ns my.web.app | |
(:require ["react" :as react :refer [createContext useContext]] | |
["react-dom" :as react-dom] | |
[rumext.alpha :as mf] | |
[applied-science.js-interop :as j] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; https://github.com/leonoel/missionary/tree/master/doc/tutorials | |
(ns my.web.app | |
(:require [missionary.core :as m])) | |
;; Basic how the `task` used in practice | |
(def slow-mo-hello-task | |
(m/sp (println "hello") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#{\† \ \á \Â \â \™ \¤ \¥ \ˆ \€ \Î \‰ \° \± \² \– \³ \´ \µ \× \‘ \’ \º \“ \”} |