@sgrsoft/vpe-react-sdk 0.1.10 → 0.1.12
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 +38 -6
- package/dist/vpe-react-sdk.es.js +7094 -6968
- package/dist/vpe-react-sdk.umd.js +15 -15
- package/package.json +11 -5
package/README.md
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Video Player Enhancement React SDK
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
<img src="https://tkmenfxu2702.edge.naverncp.com/profile/202602/76303c7f18eb7e2e70c0e1a152419545.png" style="max-width:600px">
|
|
4
|
+
|
|
5
|
+
React 19/Vite 기반 Video Player Enhancement SDK입니다. `hls.js`/`dashjs`는 번들에 포함되지 않으며 외부에서 주입합니다.
|
|
4
6
|
|
|
5
7
|
## Modules 이용하기
|
|
6
8
|
|
|
@@ -36,8 +38,6 @@ export function App() {
|
|
|
36
38
|
return (
|
|
37
39
|
<VpePlayer
|
|
38
40
|
accessKey="YOUR_ACCESS_KEY"
|
|
39
|
-
platform="pub"
|
|
40
|
-
stage="prod"
|
|
41
41
|
hls={Hls}
|
|
42
42
|
dashjs={dashjs}
|
|
43
43
|
options={{
|
|
@@ -54,6 +54,28 @@ export function App() {
|
|
|
54
54
|
}
|
|
55
55
|
```
|
|
56
56
|
|
|
57
|
+
## platform 안내
|
|
58
|
+
`platform`은 재생 환경을 구분하는 필수 설정입니다.
|
|
59
|
+
- `pub`: 민간 클라우드 환경
|
|
60
|
+
- `gov`: 공공 클라우드 환경
|
|
61
|
+
|
|
62
|
+
```tsx
|
|
63
|
+
<VpePlayer
|
|
64
|
+
accessKey="YOUR_ACCESS_KEY"
|
|
65
|
+
platform="pub"
|
|
66
|
+
hls={Hls}
|
|
67
|
+
dashjs={dashjs}
|
|
68
|
+
|
|
69
|
+
options={{
|
|
70
|
+
playlist: [
|
|
71
|
+
{
|
|
72
|
+
file: "https://CDN_DOMAIN/example_video_01.mp4"
|
|
73
|
+
}
|
|
74
|
+
],
|
|
75
|
+
}}
|
|
76
|
+
/>
|
|
77
|
+
```
|
|
78
|
+
|
|
57
79
|
## 옵션 레퍼런스
|
|
58
80
|
`options`는 `vpe-core-sdk`에서 검증/보정됩니다. 기본값은 코어에서 결정되는 항목이 많아, 명시되지 않은 경우는 “vpe-core-sdk 기본값”으로 표기합니다.
|
|
59
81
|
|
|
@@ -181,8 +203,12 @@ export function App() {
|
|
|
181
203
|
<VpePlayer
|
|
182
204
|
accessKey="YOUR_ACCESS_KEY"
|
|
183
205
|
options={{
|
|
206
|
+
playlist: [
|
|
207
|
+
{
|
|
208
|
+
file: "https://CDN_DOMAIN/example_video_01.mp4"
|
|
209
|
+
}
|
|
210
|
+
],
|
|
184
211
|
keyboardShortcut: true,
|
|
185
|
-
playlist: [{ file: "https://CDN_DOMAIN/example_video_01.mp4" }],
|
|
186
212
|
}}
|
|
187
213
|
/>
|
|
188
214
|
```
|
|
@@ -632,7 +658,13 @@ Ref 인스턴스에서 `layout(nextLayout, merge?)`를 호출하면 즉시 반
|
|
|
632
658
|
import { setup } from "@sgrsoft/vpe-react-sdk";
|
|
633
659
|
|
|
634
660
|
const instance = setup("#video", "YOUR_ACCESS_KEY", {
|
|
635
|
-
options: {
|
|
661
|
+
options: {
|
|
662
|
+
playlist: [
|
|
663
|
+
{
|
|
664
|
+
file: "https://CDN_DOMAIN/example_video_01.mp4"
|
|
665
|
+
}
|
|
666
|
+
],
|
|
667
|
+
},
|
|
636
668
|
});
|
|
637
669
|
|
|
638
670
|
instance.layout({
|