Skip to content

Commit

Permalink
v0.2.26
Browse files Browse the repository at this point in the history
  • Loading branch information
borkdude committed Sep 17, 2023
1 parent 5847ae1 commit 18e2112
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

[Squint](https://github.com/squint-cljs/squint): ClojureScript syntax to JavaScript compiler

## 0.2.26 (2023-09-17)

- `squint repl` improvements

## 0.2.25 (2023-09-17)

- Do not resolve binding in `catch` to core var
Expand Down
20 changes: 18 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ need the extra performance, startup time and/or small bundle size.
- Keywords are translated into strings
- Maps, sequences and vectors are represented as mutable objects and arrays
- Most functions return arrays and objects, not custom data structures
- Supports async/await:`(def x (js/await y))`. Async functions must be marked
- Supports async/await:`(def x (js-await y))`. Async functions must be marked
with `^:async`: `(defn ^:async foo [])`.
- `assoc!`, `dissoc!`, `conj!`, etc. perform in place mutation on objects
- `assoc`, `dissoc`, `conj`, etc. return a new shallow copy of objects
Expand Down Expand Up @@ -172,7 +172,7 @@ squint supports `async/await`:
``` clojure
(defn ^:async foo [] (js/Promise.resolve 10))

(def x (js/await (foo)))
(def x (js-await (foo)))

(println x) ;;=> 10
```
Expand All @@ -196,6 +196,22 @@ const f = eval(compileString("(fn [] 1)"
console.log(f()); // prints 1
```

## REPL

Squint has a console repl which can be started with `squint repl`.

### Emacs

You can use this together with `inf-clojure` in emacs as follows:

In a `.cljs` buffer, type `M-x inf-clojure`. Then enter the startup command `npx
squint repl` (or `bunx --bun repl`) and select the `clojure` or `babashka` type
REPL. REPL away!

## Svelte

A svelte pre-processor for squint can be found [here](https://github.com/jruz/svelte-preprocess-cljs).

License
=======

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "squint-cljs",
"type": "module",
"sideEffects": false,
"version": "0.2.25",
"version": "0.2.26",
"files": [
"core.js",
"src/squint/core.js",
Expand Down

0 comments on commit 18e2112

Please sign in to comment.