Skip to content

Commit

Permalink
Submodule system using hooks (prebid#3924)
Browse files Browse the repository at this point in the history
* prebid-core only contains src and a few node_modules

* add back removed neverBundle to webpack build

* add module and submodule hooks

* allow vargs for submodules for flexibility

* fix jsdoc type syntax

* updated id5 userid submodule for submodule bundle size duplication fix

* add id5 userid submodule to .submodules

* fix opt out logic

* spelling fix to comment

* update to automatically include 'pubcommon' and 'unifiedid' (uncomment to optional submodule for prebid3.0)

* additional update to automatically include 'pubcommon' and 'unifiedid'

* additional update to automatically include 'pubcommon' and 'unifiedid'

* merged differences from master

* adpod changes to support submodules

* fix --modules argument with .json to work correctly with submodules

* fix to remove included and duplicated submodules
  • Loading branch information
snapwich authored and Alex committed Aug 2, 2019
1 parent bf6e3a6 commit 3d746dc
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 108 deletions.
1 change: 1 addition & 0 deletions gulpHelpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ const BUILD_PATH = './build/dist';
const DEV_PATH = './build/dev';
const ANALYTICS_PATH = '../analytics';


// get only subdirectories that contain package.json with 'main' property
function isModuleDirectory(filePath) {
try {
Expand Down
42 changes: 0 additions & 42 deletions modules/pubCommonIdSystem.js

This file was deleted.

55 changes: 0 additions & 55 deletions modules/unifiedIdSystem.js

This file was deleted.

13 changes: 2 additions & 11 deletions modules/userId/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,22 +160,13 @@ function getStoredValue(storage) {
return storedValue;
}

/**
* test if consent module is present, and if GDPR applies
* @param {ConsentData} consentData
* @returns {boolean}
*/
export function isGDPRApplicable(consentData) {
return consentData && typeof consentData.gdprApplies === 'boolean' && consentData.gdprApplies;
}

/**
* test if consent module is present, applies, and is valid for local storage or cookies (purpose 1)
* @param {ConsentData} consentData
* @returns {boolean}
*/
export function hasGDPRConsent(consentData) {
if (isGDPRApplicable(consentData)) {
function hasGDPRConsent(consentData) {
if (consentData && typeof consentData.gdprApplies === 'boolean' && consentData.gdprApplies) {
if (!consentData.consentString) {
return false;
}
Expand Down

0 comments on commit 3d746dc

Please sign in to comment.