'React Native import or include JS file

if i have more than 300 Functional Components file that i need to import in a file called "main.js",and instead of adding 300 lines of imports like so :

import C1 from "./pages/C1";

.

.

.

import C300 from "./pages/C300";

i want to put those 300 imports in an external file called "myImports.js" ,then include/import this "myImports.js" in "main.js"



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source