Security News
PyPI’s New Archival Feature Closes a Major Security Gap
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
@demos-europe/dp-consent
Advanced tools
This is a small script that allows to manage cookie consent for optional cookies.
import { dpConsent } from 'cookie-consent/dist/dp-consent.es.min.js'
// initializing dp consent
const consent = dpConsent({
notice: '', // text to be shown in the cookie slideout
optionalCookies: [
{
name: '', // the cookie's name
explanation: '' // what does this cookie do
},
{ ... }
], // an array of optional cookies
necessaryCookies: [ /* same structure as above */ ], // an array of necessary cookies
onGrantConsent: () => {}, // callback to be executed when consent is granted
onRevokeConsent: () => {} // callback to be executed when consent is revoked
})
// adjusting consent settings
consent.adjustSettings()
Dp-Cookie-Consent will show a slideout providing options to accept all cookies or to change cookie settings. If all cookies are accepted the onGrantConsent-callback will be executed and all optional cookies can be set. If the user opts to change cookie settings a modal will be opened that presents the user with a list of all necessary and all optional cookies. If the user selects optional cookies and saves these settings, the onGrantConsent-callback will be executed. If the user doesn't select optional cookies the onRevokeConsent-callback will be executed. A cookie will be set that remembers the user's choice. The cookie expires within one year.
FAQs
A cookie consent solution.
The npm package @demos-europe/dp-consent receives a total of 92 weekly downloads. As such, @demos-europe/dp-consent popularity was classified as not popular.
We found that @demos-europe/dp-consent demonstrated a healthy version release cadence and project activity because the last version was released less than 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
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Research
Security News
Malicious npm package postcss-optimizer delivers BeaverTail malware, targeting developer systems; similarities to past campaigns suggest a North Korean connection.
Security News
CISA's KEV data is now on GitHub, offering easier access, API integration, commit history tracking, and automated updates for security teams and researchers.