Skip to content

Commit dbd999f

Browse files
committed
docs improvement
1 parent 9968a54 commit dbd999f

File tree

1 file changed

+22
-6
lines changed

1 file changed

+22
-6
lines changed

readme.md

Lines changed: 22 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,33 @@ It was built to be an improvement on :
3232

3333
---
3434

35-
# Technical Info
35+
## Installation / use
36+
37+
```javascript
38+
import EditorJS from '@editorjs/editorjs';
39+
import editorjsCodeflask from '@calumk/editorjs-codeflask';
40+
41+
var editor = EditorJS({
42+
// ...
43+
tools: {
44+
...
45+
code : editorjsCodeflask
46+
},
47+
});
48+
```
49+
3650

3751
## Data Format
3852
The data imported/exported from the block is as follows:
3953

40-
| Name | Description |
41-
| --------------- | ---------------------------------------------------------- |
42-
| code | The code that is displayed in the editor, with line breaks |
43-
| language | The programming language |
44-
| showlinenumbers | Will show/hide the line numbers (Default true) (WIP - [Codeflask #132](https://github.com/kazzkiq/CodeFlask/issues/132)) |
54+
| Name | Description |
55+
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
56+
| code | The code that is displayed in the editor, with line breaks |
57+
| language (optional) | The programming language |
58+
| showlinenumbers (optional) | Will show/hide the line numbers (Default true) (WIP - [Codeflask #132](https://github.com/kazzkiq/CodeFlask/issues/132)) |
59+
4560

61+
Since language and linenumbers are optional, existing ```code``` blocks can safley use this plugin
4662

4763

4864

0 commit comments

Comments
 (0)