-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[JW Player Video Provider][Video JS Video Provider]: Add missing typedefs #11901
Conversation
Whoa there, partner! 🌵🤠 We wrangled some duplicated code in your PR:
Reducing code duplication by importing common functions from a library not only makes our code cleaner but also easier to maintain. Please move the common code from both files into a library and import it in each. Keep up the great work! 🚀 |
Whoa there, partner! 🌵🤠 We wrangled some duplicated code in your PR:
Reducing code duplication by importing common functions from a library not only makes our code cleaner but also easier to maintain. Please move the common code from both files into a library and import it in each. Keep up the great work! 🚀 |
Whoa there, partner! 🌵🤠 We wrangled some duplicated code in your PR:
Reducing code duplication by importing common functions from a library not only makes our code cleaner but also easier to maintain. Please move the common code from both files into a library and import it in each. Keep up the great work! 🚀 |
It is possible to import types, @chernodub did it here https://github.com/prebid/Prebid.js/blob/master/src/types/ortb2.d.ts |
https://github.com/prebid/Prebid.js/pull/11902/files is also importing types |
Whoa there, partner! 🌵🤠 We wrangled some duplicated code in your PR:
Reducing code duplication by importing common functions from a library not only makes our code cleaner but also easier to maintain. Please move the common code from both files into a library and import it in each. Keep up the great work! 🚀 |
Whoa there, partner! 🌵🤠 We wrangled some duplicated code in your PR:
Reducing code duplication by importing common functions from a library not only makes our code cleaner but also easier to maintain. Please move the common code from both files into a library and import it in each. Keep up the great work! 🚀 |
modules/videojsVideoProvider.js
Outdated
@@ -13,9 +13,6 @@ import { submodule } from '../src/hook.js'; | |||
import stateFactory from '../libraries/video/shared/state.js'; | |||
import { PLAYBACK_MODE } from '../libraries/video/constants/constants.js'; | |||
import { getEventHandler } from '../libraries/video/shared/eventHandler.js'; | |||
/** | |||
* @typedef {import('../libraries/video/shared/state.js').State} State |
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.
Why revert this? looks like it worked
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.
THe duplication check is buggy . I tried to see if reducing the amount of files changed could limit its scope, but that's not the case.
Whoa there, partner! 🌵🤠 We wrangled some duplicated code in your PR:
Reducing code duplication by importing common functions from a library not only makes our code cleaner but also easier to maintain. Please move the common code from both files into a library and import it in each. Keep up the great work! 🚀 |
Thanks! |
…defs (prebid#11901) * adds missing typedefs * revert videojs * restore videojs * uses typedef import statements * unifies statements * undo videojs * restore import
…defs (prebid#11901) * adds missing typedefs * revert videojs * restore videojs * uses typedef import statements * unifies statements * undo videojs * restore import
Type of change
Description of change
Adds missing typedefs for types that are referenced to avoid linter warnings.
It would be nice if the types could be shared to reduce duplication