Skip to content

Commit dfe91e1

Browse files
committed
build: exclude src/examples from published dist
Examples are meant to be read and run from the repo via tsx, not imported from the package. Excluding them from the prod/cjs build configs means dist/{esm,cjs}/examples/ is no longer produced and no longer ships in the npm tarball. Follow-up to #1579 / #1553.
1 parent bf1e022 commit dfe91e1

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

tsconfig.cjs.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@
66
"outDir": "./dist/cjs"
77
},
88
"include": ["src/**/*"],
9-
"exclude": ["**/*.test.ts", "src/__mocks__/**/*", "src/__fixtures__/**/*"]
9+
"exclude": ["**/*.test.ts", "src/__mocks__/**/*", "src/__fixtures__/**/*", "src/examples/**/*"]
1010
}

tsconfig.prod.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
"outDir": "./dist/esm"
55
},
66
"include": ["src/**/*"],
7-
"exclude": ["**/*.test.ts", "src/__mocks__/**/*", "src/__fixtures__/**/*"]
7+
"exclude": ["**/*.test.ts", "src/__mocks__/**/*", "src/__fixtures__/**/*", "src/examples/**/*"]
88
}

0 commit comments

Comments
 (0)