Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
svelte-claps
Advanced tools
Adds clap button (like medium) to any page for your SvelteKit apps.
This package originally was created for Next.js by @upstash
Nothing to maintain, it is completely serverless 💯
Create a free Redis database at Upstash Console
We will use Upstash Redis to keep the data as well as messaging (Redis pub/sub).
Copy the .env.local.example
file to .env.local
(which will be ignored by
Git):
cp .env.local.example .env.local
UPSTASH_REDIS_REST_URL
andUPSTASH_REDIS_REST_TOKEN
can be found at the database details page in Upstash Console.
npm install --save svelte-claps
# or
yarn add svelte-claps
Create a new API endpoint for SvelteKit app. Import the package and expose the
GET
and PATCH
methods.
// src/routes/api/claps.js
import createClapsApi from 'svelte-claps';
export const { GET, PATCH } = createClapsApi({ maxClaps: 10 });
<Claps />
Component<script lang="ts">
import { Claps } from 'svelte-claps';
</script>
<div class="container">
<Claps replyUrl="https://twitter.com/bufgix_" />
</div>
The options can be passed as React props
key | type | default |
---|---|---|
key? | string | current page path |
fixed? | "left", "center", "right" | |
replyUrl? | string | |
apiPath? | string | /api/claps |
pathname of the page is being used as the key/identity to keep the claps count. You can override this giving the
key
attribute.
FAQs
Adds clap button (like medium) to any page for your SvelteKit apps.
The npm package svelte-claps receives a total of 1 weekly downloads. As such, svelte-claps popularity was classified as not popular.
We found that svelte-claps 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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.