econify / ad.js Goto Github PK
View Code? Open in Web Editor NEWπ Supercharge your Ads.
Home Page: https://adjs.dev
π Supercharge your Ads.
Home Page: https://adjs.dev
We are currently not pinning our versions in npm.
Since we run npm install on every build, it is possible that code we have never ran is being published.
Even though we gate our publishing with test suites, this is still a must fix.
There is a race condition causing this code (in DFP.ts
) to run even when the slot does end up having a contentUrl:
if (!slot.getContentUrl()) {
this.ad.isEmpty = true;
dispatchEvent(
Number(this.id.substring(this.id.length, this.id.length - 1)),
LOG_LEVELS.WARN,
'DFP Network',
'Ad sizes missing. Bypassing ad.',
);
resolve();
}
This causes ad lifecycle events intended for after the ad renders to think that the ad is empty when it is not.
See this article for proposed functionality
Boost visibility for automatically rerunning tests with a run script shortcut via:
...
"test:watch": "NODE_PATH=./src jest ./tests --watch",
...
Wanted to track this based on our conversation today @stephenbaldwin - please let me know if I missed anything.
In addition to making the library immutable, "Buckets" (or whatever name we choose) would:
ADJS
module would serve as a top level namespace only)Writing some tests to familiarize with ad.js (+ bonus increase coverage) and came across:
this.originalStyle = container.style;
container.style.position = 'sticky';
container.style.top = `${stickyOffset}px`;
https://github.com/Econify/ad.js/blob/master/src/plugins/Sticky.ts#L34
Understanding is original style is a reference to container.style so the next line that sets the value of container.style overwrites the original value to be preserved in this.originalStyle
(used for restoration in .onDestroy -> .cleanUp
). As is this means position and top if set are never restored to their original values onDestroy -> cleanUp
.
Fix and test coverage here: https://github.com/Econify/ad.js/tree/bugfix/restore-original-container-style-on-destroy
TSLint has been deprecated π’
Line 116 in 05c16c2
ad.js/src/utils/scrollMonitor.ts
Line 114 in 465b0fc
We shouldn't be initializing any code on import of a module, especially anything that has to do with the window as that will break the ability to import this server side
What is ippyrus?
Currently the adjs docs website is client-side rendered. Pieces of the page are loaded via XHR/Ajax.
The website fails to load when a user has an ad blocker on. Our current hypothesis is this occurs because the ad blocker seeβs βadβ in the URL and blocks the requests assuming itβs ad tracking.
The whitespace removal plugin for rollup removes conditional logic and replaces with the post operator value.
function proof(someValue?: string) {
return `Some text ${ someValue || '' }`
}
post build becomes
function proof(someValue?: string) {
return `Some text `
}
Version: 2.0.0-beta.31
When running updateCorrelator
in the DFP
network plugin the following warning is produced:
updateCorrelator has been deprecated. Please see the Google Ad Manager help page on "Pageviews in GPT" for more information: https://support.google.com/admanager/answer/183281?hl=en
According to Google's Ad Manager community experts, the updateCorrelator
function no longer works
I'm not sure what impacts this has on Ad.JS, but I do know this method is used inside resetCorrelator
when calling setAsActive
on the Page
. It may be affecting infinite scroll articles.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.