mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-16 01:26:16 -08:00
更新验证方式
This commit is contained in:
1 parent
87a68beeb7
commit
c5c5d6cf04
6 files changed
+88
-80
No files matched your search
+2
-2
@@ -1,7 +1,7 @@
|
||||
import './style';
|
||||
import 'balloon-css/balloon.min.css';
|
||||
import { deepMerge } from './utils';
|
||||
import OptionValidator from 'option-validator';
|
||||
import optionValidator from 'option-validator';
|
||||
import scheme from './scheme';
|
||||
import config from './config';
|
||||
import Emitter from 'tiny-emitter';
|
||||
@@ -28,7 +28,7 @@ class Artplayer extends Emitter {
|
||||
super();
|
||||
this.emit('init:start');
|
||||
this.option = deepMerge({}, Artplayer.DEFAULTS, option);
|
||||
new OptionValidator(this.option, scheme);
|
||||
optionValidator(this.option, scheme);
|
||||
this.init();
|
||||
this.emit('init:end');
|
||||
}
|
||||
|
||||
+3
-1
@@ -25,7 +25,9 @@ export default {
|
||||
playbackRate: 'boolean',
|
||||
aspectRatio: 'boolean',
|
||||
loop: 'boolean',
|
||||
type: 'string',
|
||||
type: {
|
||||
type: 'string'
|
||||
},
|
||||
mimeCodec: 'string',
|
||||
layers: {
|
||||
type: 'array',
|
||||
|
||||
Reference in new issue
Block a user