Skip to content

Commit 1c64088

Browse files
committed
fix: module resolution
1 parent 432398a commit 1c64088

File tree

2 files changed

+10
-30
lines changed

2 files changed

+10
-30
lines changed

package.json

+8-29
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,11 @@
22
"name": "@animatereactnative/accordion",
33
"version": "0.1.3",
44
"description": "A React Native Accordion component, powered by React Native Reanimated layout animation that's capable of rendering and animating content that has a dynamic height.",
5-
"source": "./src/index.tsx",
6-
"main": "./lib/commonjs/index.js",
7-
"module": "./lib/module/index.js",
8-
"exports": {
9-
".": {
10-
"import": {
11-
"types": "./lib/typescript/module/src/index.d.ts",
12-
"default": "./lib/module/index.js"
13-
},
14-
"require": {
15-
"types": "./lib/typescript/commonjs/src/index.d.ts",
16-
"default": "./lib/commonjs/index.js"
17-
}
18-
}
19-
},
5+
"main": "lib/commonjs/index",
6+
"module": "lib/module/index",
7+
"types": "lib/typescript/src/index.d.ts",
8+
"react-native": "src/index",
9+
"source": "src/index",
2010
"files": [
2111
"src",
2212
"lib",
@@ -156,23 +146,12 @@
156146
"source": "src",
157147
"output": "lib",
158148
"targets": [
159-
[
160-
"commonjs",
161-
{
162-
"esm": true
163-
}
164-
],
165-
[
166-
"module",
167-
{
168-
"esm": true
169-
}
170-
],
149+
"commonjs",
150+
"module",
171151
[
172152
"typescript",
173153
{
174-
"project": "tsconfig.build.json",
175-
"esm": true
154+
"project": "tsconfig.build.json"
176155
}
177156
]
178157
]

tsconfig.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"compilerOptions": {
3-
"rootDir": "./",
3+
"baseUrl": "./",
4+
"rootDir": ".",
45
"paths": {
56
"@animatereactnative/accordion": ["./src/index"]
67
},

0 commit comments

Comments
 (0)