ZH
测试版翻译

@core / consent

1.1.0 ▾
已验证MIT
GitHub

GDPR Cookie 同意:拒绝与接受同等显著的横幅、分类、同意记录、ConsentGate 和 Consent Mode v2

代码9 个文件上下文约 743 个 token扫描通过

应用 .genpmignore 后将被注入的确切目录树。固定于

src/lib/consent/adapters/hono.ts只读 · 37d6a8f
// Adaptador Hono: `app.route('/api/consent', consentRoutes({ cookiesByCategory: { analytics: ['_ga'], marketing: ['_fbp'] } }))`.
import { Hono } from 'hono';
import { handleConsent } from './http.ts';

export function consentRoutes(opts: Parameters<typeof handleConsent>[1] = {}) {
  return new Hono().get('/', (c) => handleConsent(c.req.raw, opts)).post('/', (c) => handleConsent(c.req.raw, opts));
}

举报 @core/consent

使用 GitHub 登录后才能举报包。