Skip to content

Commit

Permalink
[sqlite] Support import expo-sqlite/next from ESM project (#27423)
Browse files Browse the repository at this point in the history
# Why

when importing `expo-sqlite/next` from an ESM project, it cannot resolve
the import.

# How

add `exports` to support `./next`

---------

Co-authored-by: Johannes Schickling <schickling.j@gmail.com>
(cherry picked from commit ddec9c0)
  • Loading branch information
Kudo committed Mar 5, 2024
1 parent 6415b68 commit 2ccee6d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/expo-sqlite/CHANGELOG.md
Expand Up @@ -11,6 +11,8 @@

### 🐛 Bug fixes

- Fixed `expo-sqlite/next` cannot be imported from an ESM project. ([#27423](https://github.com/expo/expo/pull/27423) by [@kudo](https://github.com/kudo))

### 💡 Others

## 13.2.2 — 2024-01-25
Expand Down
10 changes: 10 additions & 0 deletions packages/expo-sqlite/package.json
Expand Up @@ -5,6 +5,16 @@
"main": "build/index.js",
"types": "build/index.d.ts",
"sideEffects": false,
"exports": {
".": {
"default": "./build/index.js",
"types": "./build/index.d.ts"
},
"./next": {
"default": "./build/next/index.js",
"types": "./build/next/index.d.ts"
}
},
"scripts": {
"build": "expo-module build",
"clean": "expo-module clean",
Expand Down

0 comments on commit 2ccee6d

Please sign in to comment.