andpor / react-native-sqlite-storage

Full featured SQLite3 Native Plugin for React Native (Android and iOS)
MIT License
2.73k stars 521 forks source link

Adding SQLite bundled with this library (includes support for FTS5) does not build #416

Open 386sx opened 4 years ago

386sx commented 4 years ago
## Expected Behavior Using bundled SQLite should work after adding configuration to react-native.config.js ## Current Behavior Build crashes with `PackageList.java:17: error: package io.liteglue does not exist import io.liteglue.SQLitePluginPackage; ^ /android/app/build/generated/rncli/src/main/java/com/facebook/react/PackageList.java:99: error: cannot find symbol new SQLitePluginPackage(), ^ symbol: class SQLitePluginPackage location: class PackageList ` ## Steps to Reproduce (for bugs) Follow the instructions on https://github.com/andpor/react-native-sqlite-storage#how-to-use-android ## Context Just trying to add the FTS5 version to my project. Builds succeed without the configuration snippet mentionened above. ## Your Environment

Debug logs

PackageList.java:17: error: package io.liteglue does not exist import io.liteglue.SQLitePluginPackage; ^ /android/app/build/generated/rncli/src/main/java/com/facebook/react/PackageList.java:99: error: cannot find symbol new SQLitePluginPackage(), ^ symbol: class SQLitePluginPackage location: class PackageList

chaselal commented 3 years ago

I tried updating react-native.config.js as described in the react-native >= 0.60 instructions at https://github.com/andpor/react-native-sqlite-storage#how-to-use-android, but that did not work. Then, I tried following the instructions for react-native <= 0.59 and encountered the same problem as the OP. I tried to hack around the issue by changing io.liteglue to another SQLitePluginPackage that was available from some other package, but that did not work.

psvnlsaikumar commented 2 years ago

did anyone get this working?

poltak commented 4 weeks ago

I'm still getting this problem

        "react-native": "0.64.3",
        "react-native-sqlite-storage": "^6.0.1",
LaGregance commented 2 weeks ago

Hi,

I've created a fork of this repository that bring multiple things:

The fork is a drop in remplacement of this repository.

It should solve your problem as the fork only manage SQLite using the bundled version.

To see it, click here: https://www.npmjs.com/package/@boltcode/react-native-sqlite-storage

If you want to understand what I've done in this fork, there is a documentation about it.

Have a good day.