-
Notifications
You must be signed in to change notification settings - Fork 7.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clean up and documentation of src/js/video.js and DOM functions #2182
Conversation
@@ -70,7 +68,7 @@ export const insertFirst = function(child, parent){ | |||
* @type {Object} | |||
* @private | |||
*/ | |||
export const cache = {}; | |||
const _data = {}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since this isn't exported, there's no need for the _
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool. Is that the common practice? Add an underscore only to private vars that are going to be accessible externally?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep.
other than the |
Options['languages'][code] = data; | ||
} | ||
return Options['languages']; | ||
return merge(globalOptions.languages, { [code]: data })[code]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NICE
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Preparing to export utility functions on the videojs object closes videojs#2182 Change el() to getEl() for consistency Cleaned up DOM functions library Clean up and document videojs object API Fixed mergeOptions to modify the first object instead of a copy More cleanup of the main video.js file and documentation Fixed issues with mergeOptions Cleaned up the addLanguage function Removed unnecessary underscores in private module vars
videojs
object.