diff --git a/.github/workflows/ci-cloudflare-access.yml b/.github/workflows/ci-cloudflare-access.yml index 84327200..3270ecad 100644 --- a/.github/workflows/ci-cloudflare-access.yml +++ b/.github/workflows/ci-cloudflare-access.yml @@ -19,6 +19,7 @@ jobs: node-version: 20.x - run: yarn workspaces focus hono-middleware @hono/cloudflare-access - run: yarn workspace @hono/cloudflare-access build + - run: yarn workspace @hono/cloudflare-access publint - run: yarn test --coverage --project @hono/cloudflare-access - uses: codecov/codecov-action@v5 with: diff --git a/packages/cloudflare-access/package.json b/packages/cloudflare-access/package.json index a7b566a7..3cce5fc4 100644 --- a/packages/cloudflare-access/package.json +++ b/packages/cloudflare-access/package.json @@ -9,10 +9,10 @@ "dist" ], "scripts": { - "test": "vitest --run", - "build": "tsup ./src/index.ts --format esm,cjs --dts", - "publint": "publint", - "release": "yarn build && yarn test && yarn publint && yarn publish" + "build": "tsup ./src/index.ts", + "prepack": "yarn build", + "publint": "attw --pack && publint", + "test": "vitest" }, "exports": { ".": { @@ -33,15 +33,19 @@ }, "repository": { "type": "git", - "url": "https://github.com/honojs/middleware.git" + "url": "git+https://github.com/honojs/middleware.git", + "directory": "packages/cloudflare-access" }, "homepage": "https://github.com/honojs/middleware", "peerDependencies": { "hono": "*" }, "devDependencies": { + "@arethetypeswrong/cli": "^0.17.4", + "@cloudflare/workers-types": "^4.20230307.0", "hono": "^4.4.12", - "tsup": "^8.1.0", + "publint": "^0.3.9", + "tsup": "^8.4.0", "vitest": "^3.0.8" } -} +} \ No newline at end of file diff --git a/packages/cloudflare-access/tsconfig.json b/packages/cloudflare-access/tsconfig.json index acfcd843..60494f8f 100644 --- a/packages/cloudflare-access/tsconfig.json +++ b/packages/cloudflare-access/tsconfig.json @@ -1,10 +1,7 @@ { "extends": "../../tsconfig.json", "compilerOptions": { - "rootDir": "./src", "outDir": "./dist", - }, - "include": [ - "src/**/*.ts" - ], -} \ No newline at end of file + "types": ["@cloudflare/workers-types"] + } +} diff --git a/yarn.lock b/yarn.lock index ec6d6b76..cf149d64 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2517,9 +2517,11 @@ __metadata: version: 0.0.0-use.local resolution: "@hono/cloudflare-access@workspace:packages/cloudflare-access" dependencies: + "@arethetypeswrong/cli": "npm:^0.17.4" + "@cloudflare/workers-types": "npm:^4.20230307.0" hono: "npm:^4.4.12" - tsup: "npm:^8.1.0" - vitest: "npm:^3.0.8" + publint: "npm:^0.3.9" + tsup: "npm:^8.4.0" peerDependencies: hono: "*" languageName: unknown