mirror of
				https://gitea.invidious.io/iv-org/videojs-quality-selector.git
				synced 2024-08-15 00:43:13 +00:00 
			
		
		
		
	Merge pull request #76 from pbredenberg/pb/chore-standardization-upgrades
chore: upgrade standardization and configure markdownlint
This commit is contained in:
		
						commit
						8b1a082061
					
				
					 5 changed files with 425 additions and 261 deletions
				
			
		
							
								
								
									
										3
									
								
								.markdownlint.json
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								.markdownlint.json
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,3 @@ | ||||||
|  | { | ||||||
|  |    "extends": "./node_modules/@silvermine/standardization/.markdownlint.json" | ||||||
|  | } | ||||||
							
								
								
									
										17
									
								
								Gruntfile.js
									
										
									
									
									
								
							
							
						
						
									
										17
									
								
								Gruntfile.js
									
										
									
									
									
								
							|  | @ -6,7 +6,8 @@ | ||||||
| 'use strict'; | 'use strict'; | ||||||
| 
 | 
 | ||||||
| var path = require('path'), | var path = require('path'), | ||||||
|     getCodeVersion = require('silvermine-serverless-utils/src/get-code-version'); |     getCodeVersion = require('silvermine-serverless-utils/src/get-code-version'), | ||||||
|  |     markdownlint = require('markdownlint'); | ||||||
| 
 | 
 | ||||||
| const sass = require('node-sass'); | const sass = require('node-sass'); | ||||||
| 
 | 
 | ||||||
|  | @ -137,6 +138,17 @@ module.exports = function(grunt) { | ||||||
|          }, |          }, | ||||||
|       }, |       }, | ||||||
| 
 | 
 | ||||||
|  |       markdownlint: { | ||||||
|  |          all: { | ||||||
|  |             // Adjust `src` depending on how many files need to be linted:
 | ||||||
|  |             src: [ 'README.md' ], | ||||||
|  |             options: { | ||||||
|  |                // eslint-disable-next-line no-sync
 | ||||||
|  |                config: markdownlint.readConfigSync('.markdownlint.json'), | ||||||
|  |             }, | ||||||
|  |          }, | ||||||
|  |       }, | ||||||
|  | 
 | ||||||
|    }); |    }); | ||||||
| 
 | 
 | ||||||
|    grunt.loadNpmTasks('grunt-contrib-uglify'); |    grunt.loadNpmTasks('grunt-contrib-uglify'); | ||||||
|  | @ -147,8 +159,9 @@ module.exports = function(grunt) { | ||||||
|    grunt.loadNpmTasks('grunt-contrib-clean'); |    grunt.loadNpmTasks('grunt-contrib-clean'); | ||||||
|    grunt.loadNpmTasks('grunt-sass'); |    grunt.loadNpmTasks('grunt-sass'); | ||||||
|    grunt.loadNpmTasks('grunt-stylelint'); |    grunt.loadNpmTasks('grunt-stylelint'); | ||||||
|  |    grunt.loadNpmTasks('grunt-markdownlint'); | ||||||
| 
 | 
 | ||||||
|    grunt.registerTask('standards', [ 'eslint', 'stylelint' ]); |    grunt.registerTask('standards', [ 'eslint', 'stylelint', 'markdownlint' ]); | ||||||
|    grunt.registerTask('build-js', [ 'browserify', 'uglify' ]); |    grunt.registerTask('build-js', [ 'browserify', 'uglify' ]); | ||||||
|    grunt.registerTask('build-css', [ 'sass', 'postcss' ]); |    grunt.registerTask('build-css', [ 'sass', 'postcss' ]); | ||||||
|    grunt.registerTask('build', [ 'build-js', 'build-css' ]); |    grunt.registerTask('build', [ 'build-js', 'build-css' ]); | ||||||
|  |  | ||||||
							
								
								
									
										10
									
								
								README.md
									
										
									
									
									
								
							
							
						
						
									
										10
									
								
								README.md
									
										
									
									
									
								
							|  | @ -31,14 +31,14 @@ for `videojs` at `window.videojs`). | ||||||
| There is an example of this in | There is an example of this in | ||||||
| [`docs/demo/index.html`](./docs/demo/index.html). | [`docs/demo/index.html`](./docs/demo/index.html). | ||||||
| 
 | 
 | ||||||
| ##### From local file: | ##### From local file | ||||||
| 
 | 
 | ||||||
| ```js | ```js | ||||||
| <script src="./path/to/video.min.js"></script> | <script src="./path/to/video.min.js"></script> | ||||||
| <script src="./path/to/silvermine-videojs-quality-selector.min.js"></script> | <script src="./path/to/silvermine-videojs-quality-selector.min.js"></script> | ||||||
| ``` | ``` | ||||||
| 
 | 
 | ||||||
| ##### From [`unpkg`](https://unpkg.com/@silvermine/videojs-quality-selector/): | ##### From [`unpkg`](https://unpkg.com/@silvermine/videojs-quality-selector/) | ||||||
| 
 | 
 | ||||||
| ```js | ```js | ||||||
| <link href="https://unpkg.com/@silvermine/videojs-quality-selector/dist/css/quality-selector.css" rel="stylesheet"> | <link href="https://unpkg.com/@silvermine/videojs-quality-selector/dist/css/quality-selector.css" rel="stylesheet"> | ||||||
|  | @ -50,7 +50,7 @@ There is an example of this in | ||||||
| 
 | 
 | ||||||
| When using NPM/Browserify, first install the plugin. | When using NPM/Browserify, first install the plugin. | ||||||
| 
 | 
 | ||||||
| ``` | ```bash | ||||||
| npm install --save @silvermine/videojs-quality-selector | npm install --save @silvermine/videojs-quality-selector | ||||||
| ``` | ``` | ||||||
| 
 | 
 | ||||||
|  | @ -113,13 +113,13 @@ player.src([ | ||||||
| There are at least two ways to add the quality selector control to the player's control | There are at least two ways to add the quality selector control to the player's control | ||||||
| bar. The first is directly adding it via `addChild`. For example: | bar. The first is directly adding it via `addChild`. For example: | ||||||
| 
 | 
 | ||||||
| ``` | ```js | ||||||
| player.controlBar.addChild('QualitySelector'); | player.controlBar.addChild('QualitySelector'); | ||||||
| ``` | ``` | ||||||
| 
 | 
 | ||||||
| The second option is to add the control via the player's options, for instance: | The second option is to add the control via the player's options, for instance: | ||||||
| 
 | 
 | ||||||
| ``` | ```js | ||||||
| var options, player; | var options, player; | ||||||
| 
 | 
 | ||||||
| options = { | options = { | ||||||
|  |  | ||||||
							
								
								
									
										654
									
								
								package-lock.json
									
										
									
										generated
									
									
									
								
							
							
						
						
									
										654
									
								
								package-lock.json
									
										
									
										generated
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load diff
											
										
									
								
							|  | @ -27,7 +27,7 @@ | ||||||
|   "homepage": "https://github.com/silvermine/videojs-quality-selector#readme", |   "homepage": "https://github.com/silvermine/videojs-quality-selector#readme", | ||||||
|   "devDependencies": { |   "devDependencies": { | ||||||
|     "@silvermine/eslint-config": "3.0.1", |     "@silvermine/eslint-config": "3.0.1", | ||||||
|     "@silvermine/standardization": "1.1.0", |     "@silvermine/standardization": "1.2.0", | ||||||
|     "autoprefixer": "8.6.5", |     "autoprefixer": "8.6.5", | ||||||
|     "check-node-version": "4.0.3", |     "check-node-version": "4.0.3", | ||||||
|     "coveralls": "3.0.3", |     "coveralls": "3.0.3", | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue