wsq-api
v0.3.19
Published
An API for widesquare contentpages
Downloads
85
Readme
wsq-api
An API for widesquare contentpages
Features
- Forwards query params from campaigns
- Fetches query
- Enables custom tracking for all tags available in ./tracking/*
currently supporting
- bing
Setup
Options
- Rewrites all URLs inside the given CSS
selector
- Will skip URLs which are noted in the
blacklist
Add this code just before the </body>
tag
!function(e,t,n,s,c,a,i){e.wsqApi=c,e[c]=e[c]||function(){(e[c].q=e[c].q||[]).push(arguments)},e[c].l=1*new Date,a=t.createElement(n),i=t.getElementsByTagName(n)[0],a.async=1,a.src="//cdn.jsdelivr.net/npm/wsq-api@latest/dist/wsq.js",i.parentNode.insertBefore(a,i)}(window,document,"script",0,"wsq"),wsq("init",{selector:"main a",adSelector:"main a *",blacklist:["www.example.com"]});
Full unminified example in the src/index.html file
Manual Deployment
- Add changes to the project
- npm run build
- npm version (major|minor|patch)
- npm publish
Manually purge cdn, ask: [email protected] for the command.