-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Allow bundling from node.js or with new gulp task bundle-to-stdout #1570
Conversation
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.
gulp build
with this change results in
build/dist/prebid.js 62K
vs on master at 598817f
build/dist/prebid.js 338K
looks like all modules are getting included on master but not in the PR? To be expected?
@matthewlane no, that is a bug. should be fixed now. good catch. |
…built * 'master' of https://github.com/prebid/Prebid.js: (46 commits) Serverbid alias (prebid#1560) Add user sync to process for approving adapter PRs (prebid#1457) fix travis build (prebid#1595) Rubicon project improvement/user sync (prebid#1549) Adding Orbitsoft adapter (prebid#1378) Fix renderer test for new validation rule (prebid#1592) Allow SET_TARGETING to be used in AnalyticsAdapter (prebid#1577) Add support for video stream context (prebid#1483) Invalidate bid if matching bid request not found (prebid#1575) allow adapters to set default adserverTargeting for specific bid (prebid#1568) Custom granularity precision should honor 0 if it is passed in closes prebid#1479 (prebid#1591) BaseAdapter for the Prebid 0.x -> 1.x transition (prebid#1494) Add a version to the Criteo adapter (prebid#1573) Allow bundling from node.js or with new gulp task bundle-to-stdout (prebid#1570) Add url.parse option to not decode the whole URL (prebid#1480) Tremor Video Bid Adapter (prebid#1552) Yieldmo bid adapter (prebid#1415) Switch `gulp docs` to build its output using documentation.js (prebid#1545) Increment pre version Prebid 0.28.0 Release ...
…rebid#1570) * allow bundle task to be run programmatically from node * add bundle-to-stdout task to gulpFile.js * fixed bug with double-prepending __dirname in module bundling
Hey guys, sorry to comment here. We're trying to generate prebid bundles programmatically, and we're having any issue with the nodeBundle function, I did create an issue but it was never responded to. When I run the following: const nodeBundle = require('prebid.js/gulpfile.js')
nodeBundle(['rubiconBidAdapter'])
.then((x) => {
console.log(x);
})
.catch((e) => {
console.error(e);
}) All I get is some console messages and then it instantly exits the process.
Nothing is built, or logged. Node version: v8.11.2 Would really love some feedback on this, happy to submit a PR if given some direction. @snapwich |
…rebid#1570) * allow bundle task to be run programmatically from node * add bundle-to-stdout task to gulpFile.js * fixed bug with double-prepending __dirname in module bundling
Type of change
Description of change
Can be used in node.js like so:
Or can print the bundle to stdout like so:
gulp bundle-to-stdout --modules=rubiconBidAdapter,currency > prebid.js