tex-editor 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/package.json +8 -1
package/README.md
CHANGED
|
@@ -51,7 +51,7 @@ npm install tex-editor
|
|
|
51
51
|
```javascript
|
|
52
52
|
import tex from 'tex-editor'
|
|
53
53
|
// don't forget the stylesheet:
|
|
54
|
-
import 'tex-editor/
|
|
54
|
+
import 'tex-editor/tex.css'
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
Then add HTML elements where you want to display the text editors:
|
|
@@ -126,7 +126,7 @@ using a `ref`, and tear it down in the cleanup function.
|
|
|
126
126
|
```jsx
|
|
127
127
|
import { useEffect, useRef } from 'react'
|
|
128
128
|
import tex from 'tex-editor'
|
|
129
|
-
import 'tex-editor/
|
|
129
|
+
import 'tex-editor/tex.css'
|
|
130
130
|
|
|
131
131
|
export default function TexEditor({ value = '', onChange }) {
|
|
132
132
|
const ref = useRef(null)
|
package/package.json
CHANGED
|
@@ -1,11 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tex-editor",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "Ultra-lightweight WYSIWYG rich text editor in pure JavaScript, no dependencies. Works with both <textarea> and <div> elements.",
|
|
5
5
|
"main": "src/tex.js",
|
|
6
6
|
"unpkg": "src/tex.js",
|
|
7
7
|
"jsdelivr": "src/tex.js",
|
|
8
8
|
"style": "src/tex.css",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": "./src/tex.js",
|
|
11
|
+
"./tex.css": "./src/tex.css",
|
|
12
|
+
"./tex.js": "./src/tex.js",
|
|
13
|
+
"./src/*": "./src/*",
|
|
14
|
+
"./package.json": "./package.json"
|
|
15
|
+
},
|
|
9
16
|
"files": [
|
|
10
17
|
"src",
|
|
11
18
|
"README.md",
|