Archive of September 2024

Using path aliases with React Native

Path aliases in React Native

While your project scales you'll find yourself deep into the folder structure and looking at your imports from the deep down will be confusing. Plus let's face it, since IDE handles them for the most part it just looks bad as you scroll down from the top. Nevertheless it is a good practice to use aliases for your imports.

You can start with adding babel-plugin-module-resolver to your project.

yarn add -D babel-plugin-module-resolver

Adding typescript support is essential and pretty easy. Open your tsconfig.json file and add; Read More