
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
comfytwitch
Advanced tools
Comfiest Way to Add Serverless Twitch Authentication
ComfyTwitch lets you integrate Twitch authentication for websites without a server SUPER EASILY in just a few lines of code. It automatically caches the authentication in the browser so that users do not have to log in every single visit.
Like these projects? The best way to support my open-source projects is by becoming a Comfy Sponsor on GitHub!
Come and hang out with us at the Comfiest Corner on Twitch!
To see how it works, check out this static webpage that authenticates using Twitch OAuth: https://www.instafluff.tv/ComfyTwitch
Create a Twitch application from https://dev.twitch.tv/console/apps/create to generate a Twitch Client ID
Add an OAuth Redirect URL to your Twitch application for the authentication to redirect the user to afterwards. A local example would look like: http://localhost:8800/index.html
comfytwitch.min.js from the web folder or include from the JSDeliver CDN and add into every page you need authenticated:<script src="comfytwitch.min.js"></script>
OR
<script src="https://cdn.jsdelivr.net/npm/comfytwitch@latest/web/comfytwitch.min.js"></script>
ComfyTwitch.Check() for whether or not the user is logged in.
The authentication is cached in the browser so that the user does not have to log in every time.<html>
<head>
<script src="https://cdn.jsdelivr.net/npm/comfytwitch@latest/web/comfytwitch.min.js"></script>
</head>
<body>
<script type="text/javascript">
const clientId = "YOUR-CLIENT-ID";
const baseUrl = window.location.origin;
ComfyTwitch.Check()
.then( result => {
if( result ) {
// Logged In
}
else {
// Logged Out
}
});
</script>
</body>
</html>
ComfyTwitch.Login() on a button click or through a separate page, passing in the Client ID, the same Redirect URI as set in your Twitch application, and the Twitch Permission Scopes you need:ComfyTwitch.Login( "YOUR-CLIENT-ID", `http://localhost:8800/index.html`, [ "user:read:email" ] );
ComfyTwitch.Logout()( clientId, userId )
let user = await ComfyTwitch.GetUser( "YOUR-CLIENT-ID", "TWITCH-USER-ID" );
FAQs
Comfiest Way to Add Serverless Twitch Authentication
We found that comfytwitch demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.