Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kritzcreek/purescript-emmet
Quick scaffolding for Halogen's HTML DSL
https://github.com/kritzcreek/purescript-emmet
Last synced: about 2 hours ago
JSON representation
Quick scaffolding for Halogen's HTML DSL
- Host: GitHub
- URL: https://github.com/kritzcreek/purescript-emmet
- Owner: kritzcreek
- License: lgpl-3.0
- Created: 2017-06-02T06:15:55.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2021-08-28T11:42:45.000Z (about 3 years ago)
- Last Synced: 2024-04-24T20:42:09.689Z (7 months ago)
- Language: PureScript
- Homepage:
- Size: 22.5 KB
- Stars: 36
- Watchers: 3
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
purescript-emmet
==A tool for [emmet-like](https://docs.emmet.io/abbreviations/) html abbreviations
and generators in PureScript (Right now it only does Halogen, but it's easy to
write a renderer for all kinds of HTML DSLs).## Installing
`npm i -g purescript-emmet`
## Usage
`purescript-emmet` expects an abbreviation on stdin and outputs generated
halogen markup on stdout. As an example of how to use this in Emacs, add this to
your `init.el`:```emacs-lisp
(defun purescript-emmet ()
(interactive)
(let ((start (point))
(end (save-excursion (beginning-of-line-text) (point))))
(call-process-region start end "purescript-emmet" t t)))
(global-set-key (kbd "C-c C-e") 'purescript-emmet)
```(Choose whatever keybinding you prefer)
## Usage as a Library
Check `Emmet.Halogen.emmetHalogen` to see an example usage of the library and
how you'd go about writing your own renderer.## LICENSE
Copyright 2017 Christoph Hegemann
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
See the LICENSE file for further details.