File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed
packages/react-native/template Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change 1
1
const { getDefaultConfig, mergeConfig} = require ( '@react-native/metro-config' ) ;
2
+ const { getPlatformResolver} = require ( '@callstack/out-of-tree-platforms' ) ;
2
3
3
4
/**
4
5
* Metro configuration
5
6
* https://facebook.github.io/metro/docs/configuration
6
7
*
7
8
* @type {import('metro-config').MetroConfig }
8
9
*/
9
- const config = { } ;
10
+
11
+
12
+ const config = {
13
+ resolver : {
14
+ resolveRequest : getPlatformResolver ( {
15
+ platformNameMap : [ { visionos : '@callstack/react-native-visionos' } ] ,
16
+ } ) ,
17
+ } ,
18
+ } ;
10
19
11
20
module . exports = mergeConfig ( getDefaultConfig ( __dirname ) , config ) ;
Original file line number Diff line number Diff line change 22
22
"@react-native/eslint-config" : " ^0.74.0" ,
23
23
"@react-native/metro-config" : " ^0.74.0" ,
24
24
"@react-native/typescript-config" : " ^0.74.0" ,
25
+ "@callstack/out-of-tree-platforms" : " ^0.74.0" ,
25
26
"@types/react" : " ^18.2.6" ,
26
27
"@types/react-test-renderer" : " ^18.0.0" ,
27
28
"babel-jest" : " ^29.6.3" ,
You can’t perform that action at this time.
0 commit comments