mirror of
				https://github.com/videojs/video.js.git
				synced 2025-10-31 00:08:01 +02:00 
			
		
		
		
	Close GH-560: Export global players object.
This commit is contained in:
		| @@ -29,6 +29,7 @@ goog.exportSymbol('videojs', vjs); | ||||
| goog.exportSymbol('_V_', vjs); | ||||
|  | ||||
| goog.exportSymbol('videojs.options', vjs.options); | ||||
| goog.exportSymbol('videojs.players', vjs.players); | ||||
|  | ||||
| // Allow external components to use global cache | ||||
| goog.exportSymbol('videojs.cache', vjs.cache); | ||||
|   | ||||
| @@ -51,3 +51,16 @@ test('requestFullScreen and cancelFullScreen methods should exist', function() { | ||||
|  | ||||
|   player.dispose(); | ||||
| }); | ||||
|  | ||||
| test('videojs.players should be availble after minification', function() { | ||||
|   var videoTag = PlayerTest.makeTag(); | ||||
|   var id = videoTag.id; | ||||
|  | ||||
|   var fixture = document.getElementById('qunit-fixture'); | ||||
|   fixture.appendChild(videoTag); | ||||
|  | ||||
|   var player = videojs(id); | ||||
|   equal(videojs.players[id], player, 'videojs.players is available'); | ||||
|  | ||||
|   player.dispose(); | ||||
| }); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user