Voting web component

Demo of web component below


    <script src="" type="module"></script>

    <snyk-vote selector="some-specific-id"></snyk-vote>


The project origin defaults to the current origin the web component is being hosted on, but can be changed via an attribute. It's important that this remains consistent throughout your project to be able to retrieve your content and not cross pollinate other origins.

<snyk-vote origin="" selector="some-specific-id"></snyk-vote>

The vote widget also emits a vote event, and the direction of vote is contained in the event.details.positive value - true if thumbs-up, false if thumbs-down.