Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added benchmarks/with-cookiekit/app/favicon.ico
Binary file not shown.
27 changes: 27 additions & 0 deletions benchmarks/with-cookiekit/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
'use client';

/*
* If you're using Next.js, we recommend installing the @c15t/nextjs package.
* The Next.js package is a wrapper around the React package that provides
* additional features for Next.js.
*/

import {
CookieManager
} from 'react-cookie-manager';
import type { ReactNode } from 'react';


export default function RootLayout({
children,
}: Readonly<{
children: ReactNode;
}>) {
return (
<html lang="en" suppressHydrationWarning>
<body>
<CookieManager>{children}</CookieManager>
</body>
</html>
);
}
9 changes: 9 additions & 0 deletions benchmarks/with-cookiekit/app/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
export default function Home() {
return (
<div>
<h1>Benchmark</h1>
</div>
);
}


48 changes: 48 additions & 0 deletions benchmarks/with-cookiekit/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"$schema": "./node_modules/@cookiebench/benchmark-schema/schema.json",
"name": "with-cookiekit",
"iterations": 20,
"cookieBanner": {
"selectors": [
".cookie-manager",
".react-cookie-manager",
"[data-react-cookie-manager]"
],
"serviceHosts": [],
"waitForVisibility": true,
"measureViewportCoverage": true,
"expectedLayoutShift": false,
"serviceName": "Cookiekit"
},
"internationalization": {
"detection": "none",
"stringLoading": "none"
},
"techStack": {
"bundler": "vite",
"bundleType": ["esm", "cjs"],
"frameworks": ["react"],
"languages": ["typescript", "javascript"],
"packageManager": "pnpm",
"typescript": true
},
"source": {
"license": "MIT",
"github": "github.com/hypershiphq/react-cookie-manager",
"npm": "react-cookie-manager",
"website": "https://github.com/hypershiphq/react-cookie-manager",
"openSource": true,
"type": "open-source"
},
"company": {
"name": "Hypership",
"website": "https://github.com/hypershiphq",
"avatar": "https://github.com/hypershiphq.png"
},
"includes": {
"backend": [],
"components": ["react", "javascript"]
},
"tags": ["cookiekit", "react", "open source", "oss", "community"]
}

5 changes: 5 additions & 0 deletions benchmarks/with-cookiekit/next-env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
7 changes: 7 additions & 0 deletions benchmarks/with-cookiekit/next.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import type { NextConfig } from 'next';

const nextConfig: NextConfig = {};

export default nextConfig;


29 changes: 29 additions & 0 deletions benchmarks/with-cookiekit/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"name": "with-cookiekit",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev --port 3001",
"build": "next build",
"start": "next start",
"lint": "next lint",
"fmt": "pnpm biome format --write . && pnpm biome check --formatter-enabled=false --linter-enabled=false --organize-imports-enabled=true --write",
"benchmark": "pnpm exec benchmark-cli benchmark"
},
"dependencies": {
"next": "15.3.3",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"react-cookie-manager": "4.0.3"
},
"devDependencies": {
"@cookiebench/benchmark-schema": "workspace:*",
"@cookiebench/cli": "workspace:*",
"@cookiebench/ts-config": "workspace:*",
"@types/node": "^22.15.30",
"@types/react": "^19.1.6",
"@types/react-dom": "^19.1.6",
"typescript": "^5.8.3"
}
}

13 changes: 13 additions & 0 deletions benchmarks/with-cookiekit/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"extends": "../../packages/typescript-config/nextjs.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@/*": ["./*"]
}
},
"include": ["next-env.d.ts", ".next/types/**/*.ts", "**/*.ts", "**/*.tsx"],
"exclude": ["node_modules"]
}


48 changes: 48 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions react-cookie-manager
Submodule react-cookie-manager added at 6069f2