fledge.polyfill

A Fledge JavaScript polyfill.
Installation
npm install --save @magnite/fledge.polyfill
Table of Contents
Usage
Interest Groups
As of this moment, the polyfill is intended to work within the Chrome browser at a version greater than 91. There are several ways to invoke the polyfill, but given the modern capabilities of support required, the following is the recoommended way to invoke the API.
<script type="module">
import { fledge } from "./node_modules/@magnite/fledge.polyfill/esm/index.js";
const options = {
owner: "www.buyer.com",
name: "an-interest-group",
bidding_logic_url: "https://dsp.com/bidding",
};
fledge.joinAdInterestGroup(options, 864000000).then(response => console.log(response));
fledge.leaveAdInterestGroup(options).then(response => console.log(response));
</script>
Where to Find Documentation
The best way to find out what's available is to dig through source code, as each directory has a README file to describe each feature.
How We Track Changes 
This project uses a CHANGELOG and GitHub releases which contains a curated, chronologically ordered list of notable changes for each version of a project. Read more about changelogs.
How We Version 
We use SemVer for its versioning providing us an opt-in approach to releases. This means we add a version number according to the spec, as you see below. So rather than force developers to consume the latest and greatest, they can choose which version to consume and test any newer ones before upgrading. Please the read the spec as it goes into further detail.
Given a version number MAJOR.MINOR.PATCH, increment the:
- MAJOR version when you make incompatible API changes.
- MINOR version when you add functionality in a backward-compatible manner.
- PATCH version when you make backward-compatible bug fixes.
Additional labels for pre-release and build metadata are available as extensions to the MAJOR.MINOR.PATCH format.
How to Contribute 
Have a bug or a feature request? Looking to contribute to advance the project? Read our contribution guide or maintenance guide first in order to understand how we do things around here. Or you could look at some of our other guides below:
How do I… (click to expand)
Where to Find Support 
Looking to talk to someone or need some help? Please read our support guidelines.
Tools We Use
- CommitLint - Used to ensure our commits follow our standards
- Conventional Changelog - Used to generate our CHANGELOG
- ESLint - Used to lint our JavaScript
- Husky - Used for auto-fixing linting errors on each commit
- Jest - Used for testing our JavaScript and (S)CSS
- Semantic Release - Used for automating and releasing our library
References
License 
©2021 Magnite, Inc. See LICENSE for specifics.