Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/an-sh/flow-minor-mode
Emacs minor mode for editing flowtype files.
https://github.com/an-sh/flow-minor-mode
emacs emacs-mode flow flowtype
Last synced: 2 months ago
JSON representation
Emacs minor mode for editing flowtype files.
- Host: GitHub
- URL: https://github.com/an-sh/flow-minor-mode
- Owner: an-sh
- License: bsd-3-clause
- Created: 2017-02-26T16:59:24.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2020-09-05T17:30:56.000Z (over 4 years ago)
- Last Synced: 2024-11-22T23:32:05.365Z (2 months ago)
- Topics: emacs, emacs-mode, flow, flowtype
- Language: Emacs Lisp
- Homepage:
- Size: 37.1 KB
- Stars: 47
- Watchers: 4
- Forks: 16
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# flow-minor-mode
Minor mode for [flow](http://flowtype.org), which can be overlayed on
top of other modes like `web-mode`. Essentially a rewrite of an
official [flow-for-emacs](https://github.com/flowtype/flow-for-emacs)
snippet into a standalone mode with an improved usability.## Setup
To enable this mode, enable it in your preferred JavaScript mode's
hooks:```lisp
(add-hook 'js2-mode-hook 'flow-minor-enable-automatically)
````This will enable `flow-minor-mode` for a file only when there is a
`//@flow` declaration at the first line and a `.flowconfig` file is
present in the project. If you wish to enable flow-minor-mode for all
javascript files, use this instead:```lisp
(add-hook 'js2-mode-hook 'flow-minor-mode)
```## Additional integrations
### flow-js2-mode (WIP)
[flow-js2-mode](https://github.com/Fuco1/flow-js2-mode) is a major
mode for flow files.### flycheck-flow
```lisp
(with-eval-after-load 'flycheck
(flycheck-add-mode 'javascript-flow 'flow-minor-mode)
(flycheck-add-mode 'javascript-eslint 'flow-minor-mode)
(flycheck-add-next-checker 'javascript-flow 'javascript-eslint))
```### company-flow
```lisp
(with-eval-after-load 'company
(add-to-list 'company-backends 'company-flow))
```### xref (build-in)
Use standard Emacs 25.1 xref keys (`M-.` and `M-,`) for jumping to
definitions.