File tree Expand file tree Collapse file tree
packages/react-native/src/plugins Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -41,5 +41,11 @@ export default defineConfig(
4141 "vitest/valid-describe-callback" : "off" ,
4242 "vitest/no-done-callback" : "warn"
4343 }
44+ } ,
45+ {
46+ files : [ "packages/react-native/src/plugins/ReactNativeEnvironmentInfoPlugin.ts" ] ,
47+ rules : {
48+ "@typescript-eslint/no-require-imports" : "off"
49+ }
4450 }
4551) ;
Original file line number Diff line number Diff line change @@ -36,7 +36,6 @@ export class ReactNativeEnvironmentInfoPlugin implements IEventPlugin {
3636
3737 // Attempt to load expo-device info (optional dependency)
3838 try {
39- // eslint-disable-next-line @typescript-eslint/no-require-imports
4039 const Device = require ( "expo-device" ) as typeof import ( "expo-device" ) ;
4140 if ( Device ) {
4241 if ( Device . modelName ) {
@@ -56,7 +55,6 @@ export class ReactNativeEnvironmentInfoPlugin implements IEventPlugin {
5655
5756 // Attempt to load expo-application info (optional dependency)
5857 try {
59- // eslint-disable-next-line @typescript-eslint/no-require-imports
6058 const Application = require ( "expo-application" ) as typeof import ( "expo-application" ) ;
6159 if ( Application ) {
6260 ( info . data as Record < string , unknown > ) . appName = Application . applicationName ;
@@ -72,7 +70,6 @@ export class ReactNativeEnvironmentInfoPlugin implements IEventPlugin {
7270
7371 // Attempt to load expo-constants info (optional dependency)
7472 try {
75- // eslint-disable-next-line @typescript-eslint/no-require-imports
7673 const Constants = require ( "expo-constants" ) as { default : ( typeof import ( "expo-constants" ) ) [ "default" ] } ;
7774 const manifest = Constants . default ?. expoConfig ;
7875 if ( manifest ) {
You can’t perform that action at this time.
0 commit comments