gallery ad sdk
画报广告 sdk
Install
npm i @mi-gallery/ad-sdk
Usage
<script src="https://unpkg.com/@mi-gallery/ad-sdk"></script>
<script>
window.miGalleryAdSdk.fillAdById('the-dom-id');
</script>
or use ES named imports
import {fillAd, fillAdById} from '@mi-gallery/ad-sdk';
fillAdById('the-dom-id');
// or
fillAd(document.getElementById('the-dom-id'))
see test
Workflow
# develop
npm start
# build
npm run build
# test
npm test
# commit changes
npm run commit
# publish
npm publish --access=public