Skip to content
Merged
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
Empty file added examples/fetch/README.md
Empty file.
7 changes: 7 additions & 0 deletions examples/fetch/brower.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { search } from "narou/browser"

async function main() {
console.log(await search("ハーレム").execute())
}

main()
7 changes: 7 additions & 0 deletions examples/fetch/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { search } from "narou"

async function main() {
console.log(await search("ハーレム").execute())
}

main()
16 changes: 16 additions & 0 deletions examples/fetch/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "fetch",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"keywords": [],
"author": "",
"license": "ISC",
"packageManager": "pnpm@10.10.0",
"dependencies": {
"narou": "link:../.."
}
}
60 changes: 24 additions & 36 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,38 +11,26 @@
"type": "module",
"exports": {
".": {
"types": "./dist/index.d.ts",
"types": "./dist/index.d.mts",
"node": {
"import": "./dist/index.js",
"import": "./dist/index.mjs",
"require": "./dist/index.cjs"
Comment on lines +14 to 17

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Exports point to artifacts tsdown does not emit

In package.json the root export now targets ./dist/index.mjs and ./dist/index.d.mts (lines 14–17), but the build config in tsdown.config.ts still uses the default format: ["cjs", "esm"] with no out-extension override or NodeNext module settings, so tsdown will continue to emit index.js/index.cjs and .d.ts files. After running pnpm run build, the files referenced in exports will not exist, causing module resolution/type lookup errors for consumers importing narou.

Useful? React with 👍 / 👎.

},
"browser": {
"import": "./dist/index.browser.js",
"import": "./dist/index.browser.mjs",
"require": "./dist/index.browser.cjs"
},
"default": "./dist/index.js"
"default": "./dist/index.mjs"
},
"./browser": {
"types": "./dist/index.browser.d.ts",
"import": "./dist/index.browser.js",
"types": "./dist/index.browser.d.mts",
"import": "./dist/index.browser.mjs",
"require": "./dist/index.browser.cjs",
"default": "./dist/index.browser.js"
},
"./utils/*": {
"types": "./dist/utils/*.d.ts",
"import": "./dist/utils/*.js",
"require": "./dist/utils/*.cjs",
"default": "./dist/utils/*.js"
},
"./*": {
"types": "./dist/*.d.ts",
"import": "./dist/*.js",
"require": "./dist/*.cjs",
"default": "./dist/*.js"
"default": "./dist/index.browser.mjs"
}
},
"main": "dist/index.cjs",
"types": "dist/index.d.ts",
"types": "dist/index.d.mts",
"files": [
"dist",
"src",
Expand All @@ -52,7 +40,7 @@
],
"scripts": {
"build": "run-z check build:tsc",
"build:tsc": "tsup ./src",
"build:tsc": "tsdown",
"check": "run-z check:lint,check:build,test",
"check:lint": "eslint src/** test/**",
"check:build": "tsc --noEmit",
Expand All @@ -66,27 +54,27 @@
"docs:llms": "node scripts/generate-llms-txt.js"
},
"devDependencies": {
"@swc/core": "^1.11.29",
"@types/node": "^24.0.8",
"@typescript-eslint/eslint-plugin": "^8.31.1",
"@typescript-eslint/parser": "^8.31.1",
"@vitest/coverage-v8": "^3.1.2",
"@swc/core": "^1.15.3",
"@types/node": "^24.10.2",
"@typescript-eslint/eslint-plugin": "^8.49.0",
"@typescript-eslint/parser": "^8.49.0",
"@vitest/coverage-v8": "^3.2.4",
"date-fns": "^4.1.0",
"eslint": "^9.25.1",
"eslint-config-prettier": "^10.1.2",
"eslint-plugin-prettier": "^5.2.6",
"globals": "^16.0.0",
"msw": "^2.7.5",
"prettier": "^3.5.3",
"eslint": "^9.39.1",
"eslint-config-prettier": "^10.1.8",
"eslint-plugin-prettier": "^5.5.4",
"globals": "^16.5.0",
"msw": "^2.12.4",
"prettier": "^3.7.4",
"run-z": "^2.1.0",
"tsup": "^8.4.0",
"typescript": "^5.8.3",
"vitest": "^3.1.2"
"tsdown": "^0.17.2",
"typescript": "^5.9.3",
"vitest": "^3.2.4"
},
"engines": {
"node": ">=16.0.0",
"pnpm": ">=8"
},
"module": "dist/index.js",
"packageManager": "pnpm@10.10.0"
}
}
Loading
Loading