zenn-embed-elements 0.1.129 → 0.1.130
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 +15 -21
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,29 +1,23 @@
|
|
|
1
1
|
# zenn-embed-elements
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
以下の記法を利用するためにこのモジュールの読み込みが必要になります。
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
- KaTeX
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
※ v0.1.106 以降のバージョンでは zenn-embed-elements での以下の機能の提供は終了されています。
|
|
8
|
+
- ~~ツイートの埋め込み~~
|
|
9
|
+
- ~~Gistの埋め込み~~
|
|
10
|
+
- ~~Mermaidの埋め込み~~
|
|
9
11
|
|
|
10
|
-
|
|
11
|
-
export default function App(...) {
|
|
12
|
-
// init custom elements
|
|
13
|
-
useEffect(()=> import("zenn-embed-elements"),[])
|
|
12
|
+
最新のパッケージでこれらの埋め込みを行う方法についてはzenn-editorの[README](https://github.com/zenn-dev/zenn-editor#readme)をご確認ください。
|
|
14
13
|
|
|
15
|
-
// need to load twitter widgets.js to use window.twttr.createTweet
|
|
16
|
-
return (
|
|
17
|
-
<script
|
|
18
|
-
dangerouslySetInnerHTML={{
|
|
19
|
-
__html: initTwitterScriptInner
|
|
20
|
-
}}
|
|
21
|
-
/>)
|
|
22
|
-
}
|
|
23
|
-
```
|
|
24
14
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
15
|
+
Reactの場合、以下のような形でモジュールを読み込みます。
|
|
16
|
+
|
|
17
|
+
```tsx
|
|
18
|
+
export default function App(...) {
|
|
19
|
+
useEffect(()=> {
|
|
20
|
+
import("zenn-embed-elements")
|
|
21
|
+
},[])
|
|
22
|
+
}
|
|
29
23
|
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zenn-embed-elements",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.130",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Web components for embedded contents.",
|
|
6
6
|
"repository": {
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"rimraf": "^3.0.2",
|
|
29
29
|
"typescript": "^3.9.3"
|
|
30
30
|
},
|
|
31
|
-
"gitHead": "
|
|
31
|
+
"gitHead": "6b3a7fb508f248a811a32fb8b9ecb3593a253aab",
|
|
32
32
|
"publishConfig": {
|
|
33
33
|
"access": "public"
|
|
34
34
|
}
|