oakmac / clojurefmt-js

clojurefmt in JavaScript
ISC License
4 stars 0 forks source link

clojurefmt-js

A library to format Clojure code following Simple Clojure Formatting Rules.

Project Status (March 2024)

This project is under active development and I do not recommend using it for your codebase at this time unless you are very adventurous. I will publish a release to npm when the project is stable enough for Alpha usage.

Project Background and Rationale

Please see Issue #1 for an explanation of this project's genesis.

Formatting Rules

Things that clojurefmt-js does NOT do

References

Coding Style

The coding style for this library is intentionally very simple in order to make porting the algorithm to multiple languages easier. This is informed by my experience porting parinfer.js to multiple languages (parinfer-lua, parinfer.py, and others).

Here are some rules to follow:

Note: this should not be considered a definitive list. I will add to this as I come across additional cases.

Development

## run unit tests
bun test

## test a single file
bun run jest format.test.js

## lint JS
bun run lint

Notes / Misc

TODO

License

ISC License