File tree Expand file tree Collapse file tree 1 file changed +0
-27
lines changed
demos/react-native-barebones-opsqlite Expand file tree Collapse file tree 1 file changed +0
-27
lines changed Original file line number Diff line number Diff line change @@ -18,32 +18,5 @@ config.resolver.nodeModulesPaths = [
1818config . resolver . disableHierarchicalLookup = true ;
1919config . resolver . unstable_enableSymlinks = true ;
2020
21- // Needed to make `@powersync/web/umd` imports work
22- config . resolver . unstable_enablePackageExports = true ;
23-
24- config . resolver . resolveRequest = ( context , moduleName , platform ) => {
25- if ( platform === 'web' ) {
26- if ( [ 'react-native-prompt-android' , '@powersync/react-native' ] . includes ( moduleName ) ) {
27- return {
28- type : 'empty'
29- } ;
30- }
31- const mapping = { 'react-native' : 'react-native-web' , '@powersync/web' : '@powersync/web/umd' } ;
32- if ( mapping [ moduleName ] ) {
33- console . log ( 'remapping' , moduleName ) ;
34- return context . resolveRequest ( context , mapping [ moduleName ] , platform ) ;
35- }
36- } else {
37- if ( [ '@powersync/web' ] . includes ( moduleName ) ) {
38- return {
39- type : 'empty'
40- } ;
41- }
42- }
43-
44- // Ensure you call the default resolver.
45- return context . resolveRequest ( context , moduleName , platform ) ;
46- } ;
47-
4821/** @type {import('@react-native/metro-config').MetroConfig } */
4922module . exports = mergeConfig ( getDefaultConfig ( __dirname ) , config ) ;
You can’t perform that action at this time.
0 commit comments