forked from prebid/Prebid.js
-
Notifications
You must be signed in to change notification settings - Fork 1
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
[POC] - Support dependencies in modules #27
Closed
Closed
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
d52a900
checks for bid identifiers bfore accessing properties
karimMourra 432f2b7
demo
karimMourra 42b1f40
removes from submodule list
karimMourra 1deae30
imports constants
karimMourra 668fa78
moves shared out of src
karimMourra ddfc32b
depends on core
karimMourra 8e43851
adds dependency support
karimMourra 3ccc5e2
removes logs
karimMourra 0c88b4b
adds dependency entries
karimMourra 56be36d
moves video module to libraries
karimMourra 72a19e4
makes video a library
karimMourra a352a28
supports bundling
karimMourra 019fd2d
removes redundant code
karimMourra File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,76 +1,86 @@ | ||
{ | ||
"userId": [ | ||
"33acrossIdSystem", | ||
"admixerIdSystem", | ||
"adtelligentIdSystem", | ||
"akamaiDAPIdSystem", | ||
"amxIdSystem", | ||
"britepoolIdSystem", | ||
"connectIdSystem", | ||
"cpexIdSystem", | ||
"criteoIdSystem", | ||
"dacIdSystem", | ||
"deepintentDpesIdSystem", | ||
"dmdIdSystem", | ||
"fabrickIdSystem", | ||
"flocIdSystem", | ||
"hadronIdSystem", | ||
"haloIdSystem", | ||
"id5IdSystem", | ||
"ftrackIdSystem", | ||
"identityLinkIdSystem", | ||
"idxIdSystem", | ||
"imuIdSystem", | ||
"intentIqIdSystem", | ||
"justIdSystem", | ||
"kinessoIdSystem", | ||
"liveIntentIdSystem", | ||
"lotamePanoramaIdSystem", | ||
"merkleIdSystem", | ||
"mwOpenLinkIdSystem", | ||
"naveggIdSystem", | ||
"netIdSystem", | ||
"nextrollIdSystem", | ||
"novatiqIdSystem", | ||
"parrableIdSystem", | ||
"pubProvidedIdSystem", | ||
"publinkIdSystem", | ||
"quantcastIdSystem", | ||
"sharedIdSystem", | ||
"tapadIdSystem", | ||
"trustpidSystem", | ||
"uid2IdSystem", | ||
"unifiedIdSystem", | ||
"verizonMediaIdSystem", | ||
"zeotapIdPlusIdSystem", | ||
"adqueryIdSystem" | ||
], | ||
"adpod": [ | ||
"freeWheelAdserverVideo", | ||
"dfpAdServerVideo" | ||
], | ||
"rtdModule": [ | ||
"airgridRtdProvider", | ||
"browsiRtdProvider", | ||
"dgkeywordRtdProvider", | ||
"geoedgeRtdProvider", | ||
"hadronRtdProvider", | ||
"haloRtdProvider", | ||
"iasRtdProvider", | ||
"jwplayerRtdProvider", | ||
"medianetRtdProvider", | ||
"optimeraRtdProvider", | ||
"permutiveRtdProvider", | ||
"reconciliationRtdProvider", | ||
"sirdataRtdProvider", | ||
"timeoutRtdProvider", | ||
"weboramaRtdProvider" | ||
], | ||
"fpdModule": [ | ||
"enrichmentFpdModule", | ||
"validationFpdModule" | ||
], | ||
"videoModule": [ | ||
"jwplayerVideoProvider" | ||
] | ||
"parentModules": { | ||
"userId": [ | ||
"33acrossIdSystem", | ||
"admixerIdSystem", | ||
"adtelligentIdSystem", | ||
"akamaiDAPIdSystem", | ||
"amxIdSystem", | ||
"britepoolIdSystem", | ||
"connectIdSystem", | ||
"cpexIdSystem", | ||
"criteoIdSystem", | ||
"dacIdSystem", | ||
"deepintentDpesIdSystem", | ||
"dmdIdSystem", | ||
"fabrickIdSystem", | ||
"flocIdSystem", | ||
"hadronIdSystem", | ||
"haloIdSystem", | ||
"id5IdSystem", | ||
"ftrackIdSystem", | ||
"identityLinkIdSystem", | ||
"idxIdSystem", | ||
"imuIdSystem", | ||
"intentIqIdSystem", | ||
"justIdSystem", | ||
"kinessoIdSystem", | ||
"liveIntentIdSystem", | ||
"lotamePanoramaIdSystem", | ||
"merkleIdSystem", | ||
"mwOpenLinkIdSystem", | ||
"naveggIdSystem", | ||
"netIdSystem", | ||
"nextrollIdSystem", | ||
"novatiqIdSystem", | ||
"parrableIdSystem", | ||
"pubProvidedIdSystem", | ||
"publinkIdSystem", | ||
"quantcastIdSystem", | ||
"sharedIdSystem", | ||
"tapadIdSystem", | ||
"trustpidSystem", | ||
"uid2IdSystem", | ||
"unifiedIdSystem", | ||
"verizonMediaIdSystem", | ||
"zeotapIdPlusIdSystem", | ||
"adqueryIdSystem" | ||
], | ||
"adpod": [ | ||
"freeWheelAdserverVideo", | ||
"dfpAdServerVideo" | ||
], | ||
"rtdModule": [ | ||
"airgridRtdProvider", | ||
"browsiRtdProvider", | ||
"dgkeywordRtdProvider", | ||
"geoedgeRtdProvider", | ||
"hadronRtdProvider", | ||
"haloRtdProvider", | ||
"iasRtdProvider", | ||
"jwplayerRtdProvider", | ||
"medianetRtdProvider", | ||
"optimeraRtdProvider", | ||
"permutiveRtdProvider", | ||
"reconciliationRtdProvider", | ||
"sirdataRtdProvider", | ||
"timeoutRtdProvider", | ||
"weboramaRtdProvider" | ||
], | ||
"fpdModule": [ | ||
"enrichmentFpdModule", | ||
"validationFpdModule" | ||
] | ||
}, | ||
"libraries": { | ||
"video": { | ||
"files": [ | ||
"./index.js", "./constants/ortb.js", "./constants/enums.js" | ||
], | ||
"dependants": [ | ||
"jwplayerVideoProvider", | ||
"testVideoProvider" | ||
] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import { | ||
PROTOCOLS, API_FRAMEWORKS, VIDEO_MIME_TYPE, PLAYBACK_METHODS, PLACEMENT, VPAID_MIME_TYPE | ||
} from '../libraries/video/constants/ortb.js'; | ||
import { PLAYBACK_MODE } from '../libraries/video/constants/enums.js'; | ||
import { | ||
SETUP_COMPLETE, SETUP_FAILED, DESTROYED, AD_REQUEST, AD_BREAK_START, AD_LOADED, AD_STARTED, AD_IMPRESSION, AD_PLAY, | ||
AD_TIME, AD_PAUSE, AD_CLICK, AD_SKIPPED, AD_ERROR, AD_COMPLETE, AD_BREAK_END, PLAYLIST, PLAYBACK_REQUEST, | ||
AUTOSTART_BLOCKED, PLAY_ATTEMPT_FAILED, CONTENT_LOADED, PLAY, PAUSE, BUFFER, TIME, SEEK_START, SEEK_END, MUTE, VOLUME, | ||
RENDITION_UPDATE, ERROR, COMPLETE, PLAYLIST_COMPLETE, FULLSCREEN, PLAYER_RESIZE, VIEWABLE, CAST | ||
} from '../libraries/video/constants/events.js'; | ||
import stateFactory from '../libraries/video/shared/state.js'; | ||
import { VIDEO_JS_VENDOR } from '../libraries/video/constants/vendorCodes.js'; | ||
import { submodule } from '../src/hook.js'; | ||
import {registerBidder} from '../src/adapters/bidderFactory.js'; | ||
|
||
export function testProvider() { | ||
const state = stateFactory(); | ||
state.updateState(PROTOCOLS, API_FRAMEWORKS, VIDEO_MIME_TYPE, PLAYBACK_METHODS, PLACEMENT, VPAID_MIME_TYPE, SETUP_COMPLETE, SETUP_FAILED, DESTROYED, AD_REQUEST, AD_BREAK_START, AD_LOADED, AD_STARTED, AD_IMPRESSION, AD_PLAY, | ||
AD_TIME, AD_PAUSE, AD_CLICK, AD_SKIPPED, AD_ERROR, AD_COMPLETE, AD_BREAK_END, PLAYLIST, PLAYBACK_REQUEST, | ||
AUTOSTART_BLOCKED, PLAY_ATTEMPT_FAILED, CONTENT_LOADED, PLAY, PAUSE, BUFFER, TIME, SEEK_START, SEEK_END, MUTE, VOLUME, | ||
RENDITION_UPDATE, ERROR, COMPLETE, PLAYLIST_COMPLETE, FULLSCREEN, PLAYER_RESIZE, VIEWABLE, CAST, registerBidder, PLAYBACK_MODE); | ||
} | ||
|
||
testProvider.code = VIDEO_JS_VENDOR; | ||
|
||
submodule('videoModule', testProvider); |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I don't think this is the right logic to use for libraries - because the dependencies on them will not work unless they are explicitly declared in
.submodules.json
, I think this should just return the list of libraries as it's defined in there.Otherwise this allows inconsistencies when the library does not use
index.js
in the way we expect here, or the compilation of files that are not used by anyone.