Skip to content

Commit 73c9932

Browse files
committed
📝
1 parent 16bdfb7 commit 73c9932

2 files changed

Lines changed: 133 additions & 9 deletions

File tree

README.md

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -58,19 +58,21 @@ Configuration
5858
|`g:vim_jsx_pretty_colorful_config`|0|colorful config flag|
5959
6060
61-
- Disable jsx highlight (but highlight group is set to jsx syntax. so this plugin expect to add highlight settings in case of disabled.)
61+
If you set `g:vim_jsx_pretty_enable_jsx_highlight`, Disable jsx highlight.
62+
But highlight group is setten to jsx syntax. So you should set manual
63+
highlight setting.
6264
63-
```vim
64-
let g:vim_jsx_pretty_enable_jsx_highlight = 0 " default 1
65-
```
65+
```vim
66+
let g:vim_jsx_pretty_enable_jsx_highlight = 0 " default 1
67+
```
6668

67-
- Colorful style (**vim-javascript only**)
69+
Colorful style (**vim-javascript only**)
6870

69-
```vim
70-
let g:vim_jsx_pretty_colorful_config = 1 " default 0
71-
```
71+
```vim
72+
let g:vim_jsx_pretty_colorful_config = 1 " default 0
73+
```
7274

73-
### Highlight group list
75+
### Syntax group list
7476

7577
|name|place|
7678
|---|---|
@@ -81,6 +83,11 @@ Configuration
8183
|jsxString| `<tag id="sample">`<br />`________~~~~~~~~_`|
8284
|jsxCloseTag| `</tag> | <tag />`<br />`~~~~~~ | _____~~` |
8385

86+
Inspiration
87+
---
88+
89+
- [vim-jsx](https://github.com/mxw/vim-jsx)
90+
8491
LICENSE
8592
---
8693
[MIT](./LICENSE.txt)

doc/vim-jsx-pretty-doc.txt

Lines changed: 117 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
vim-jsx-pretty is syntax highlight for JSX (React.js).
2+
(https://github.com/MaxMEllon/vim-jsx-pretty)
3+
4+
version 1.0.3
5+
Author: maxmellon<[email protected]>
6+
License: MIT
7+
8+
About |vim-jsx-pretty-about|
9+
Usage |vim-jsx-pretty-usage|
10+
Install |vim-jsx-pretty-install|
11+
Config |vim-jsx-pretty-config|
12+
Detail |vim-jsx-pretty-detail|
13+
License |vim-jsx-pretty-license|
14+
Inspiration |vim-jsx-pretty-inspiration|
15+
16+
===============================================================================
17+
ABOUT *vim-jsx-pretty-about*
18+
19+
*vim-jsx-pretty* is highlight and indentation JSX (React.js) syntax.
20+
21+
Dependency Plugin:
22+
- pangloss/vim-javascript
23+
24+
===============================================================================
25+
USAGE *vim-jsx-pretty-usage*
26+
27+
Just Install it.
28+
29+
===============================================================================
30+
INSTALL *vim-jsx-pretty-install*
31+
32+
If you used plugin manager `vim-plug`, As follows. >
33+
34+
Plug 'pangloss/vim-javascript' " dependency plugin
35+
Plug 'maxmellon/vim-jsx-pretty'
36+
<
37+
===============================================================================
38+
CONFIG *vim-jsx-pretty-config*
39+
40+
- config list
41+
>
42+
| name | default | detail |
43+
|---------------------------------------|---------|----------------------|
44+
| g:vim_jsx_pretty_enable_jsx_highlight | 1 | jsx highlight flag |
45+
| g:vim_jsx_pretty_colorful_config | 0 | colorful config flag |
46+
<
47+
48+
- *g:vim_jsx_pretty_enable_jsx_highlight*
49+
50+
If you set 'g:vim_jsx_pretty_enable_jsx_highlight', Disable jsx highlight.
51+
But highlight group is setten to jsx syntax. So you should set manual
52+
highlight setting.
53+
54+
- Example: >
55+
56+
let g:vim_jsx_pretty_enable_jsx_highlight = 0
57+
58+
highlight def link jsxTag Function
59+
highlight def link jsxTagName Function
60+
highlight def link jsxString String
61+
highlight def link jsxNameSpace Function
62+
highlight def link jsxComment Error
63+
highlight def link jsxAttrib Type
64+
highlight def link jsxEscapeJs jsxEscapeJs
65+
highlight def link jsxCloseTag Identifier
66+
highlight def link jsxCloseString Identifier
67+
68+
- *g:vim_jsx_pretty_colorful_config*
69+
70+
If you set 'g:vim_jsx_pretty_colorful_config', Enable colorful config.
71+
72+
===============================================================================
73+
DETAIL *vim-jsx-pretty-detail*
74+
75+
- Syntax group list
76+
>
77+
| name | match | | |
78+
|--------------|--------------------|--------------|--------------------|
79+
| jsxTag | `<tag id="sample">`| jsxjsxAttrib | `<tag id="sample">`|
80+
| | `~~~~~~~~~~~~~~~~~`| | `_____~~__________`|
81+
|--------------|--------------------|--------------|--------------------|
82+
| jsxTagName | `<tag id="sample">`| jsxEqual | `<tag id="sample">`|
83+
| | `_~~~_____________`| | `_______~_________`|
84+
|--------------|--------------------|--------------|--------------------|
85+
| jsxString | `<tag id="sample">`| jsxCloseTag | `</tag> | <tag />`|
86+
| | `________~~~~~~~~_`| | `~~~~~~ | _____~~|
87+
|--------------|--------------------|--------------|--------------------|
88+
89+
===============================================================================
90+
LICENSE *vim-jsx-pretty-license*
91+
92+
Copyright (c) 2016 MaxMEllon
93+
MIT License
94+
Permission is hereby granted, free of charge, to any person obtaining
95+
a copy of this software and associated documentation files (the
96+
"Software"), to deal in the Software without restriction, including
97+
without limitation the rights to use, copy, modify, merge, publish,
98+
distribute, sublicense, and/or sell copies of the Software, and to
99+
permit persons to whom the Software is furnished to do so, subject to
100+
the following conditions:
101+
The above copyright notice and this permission notice shall be
102+
included in all copies or substantial portions of the Software.
103+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
104+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
105+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
106+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
107+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
108+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
109+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
110+
111+
===============================================================================
112+
INSPIREATION *vim-jsx-pretty-inspiration*
113+
114+
- vim-jsx
115+
See: https://github.com/mxw/vim-jsx
116+
117+
vim:tw=78:ts=8:ft=help:norl:

0 commit comments

Comments
 (0)