Skip to content

Commit 829b7f1

Browse files
committed
add /testing entry point
1 parent a5e1cad commit 829b7f1

File tree

2 files changed

+42
-0
lines changed

2 files changed

+42
-0
lines changed

packages/select/package.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,18 @@
66
"module": "./dist/esm/index.js",
77
"types": "./dist/index.d.ts",
88
"typesVersions": {},
9+
"exports": {
10+
".": {
11+
"import": "./dist/esm/index.js",
12+
"require": "./dist/index.js",
13+
"types": "./dist/index.d.ts"
14+
},
15+
"./testing": {
16+
"import": "./dist/esm/testing/index.js",
17+
"require": "./dist/testing/index.js",
18+
"types": "./dist/testing/index.d.ts"
19+
}
20+
},
921
"scripts": {
1022
"build": "lg build-package",
1123
"tsc": "lg build-ts",

packages/select/rollup.config.mjs

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
import {
2+
esmConfig,
3+
umdConfig,
4+
storiesConfig,
5+
} from '@lg-tools/build/config/rollup.config.mjs';
6+
7+
const esmTestUtilsConfig = {
8+
...esmConfig,
9+
input: 'src/testing/index.ts',
10+
output: {
11+
...esmConfig.output,
12+
dir: 'dist/esm/testing',
13+
},
14+
};
15+
const umdTestUtilsConfig = {
16+
...umdConfig,
17+
input: 'src/testing/index.ts',
18+
output: {
19+
...umdConfig.output,
20+
dir: 'dist/testing',
21+
},
22+
};
23+
24+
export default [
25+
esmConfig,
26+
umdConfig,
27+
esmTestUtilsConfig,
28+
umdTestUtilsConfig,
29+
storiesConfig,
30+
];

0 commit comments

Comments
 (0)