npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

react-native-template-alecpo

v0.1.2

Published

alecpo React Native Template

Downloads

10

Readme

react-native-template-alecpo

⚠️ Thanks for coming, but first...~~let's take a selfie!🤳🏻~~

You will need to ensure that the React Native development environment is working correctly. If you haven't already, I suggest taking a look here before continuing.

⚛️ About the project

The intent of this project is to provide a custom template for React Native developers that wishes to start a brand new application, not by the begin, but having a pre-built project with the most commons and populars libraries and a reasonable pattern for the folder hierarchy.

🤔 How many different libraries do we have?

  • @react-navigation/native → Provide a powerful, easy to use and completely customizable screens navigation in React Native;
  • @react-navigation/stack → Provide a stack navigation model to use on react navigation;
  • axios → "Promise based HTTP client";
  • formik → Helper to build forms in react/react-native easily;
  • prop-types → "Used as runtime type checking for React props and to document the intended types of properties passed to components";
  • react-native-masked-text → "This is a simple masked text (normal text and input text) component for React-Native";
  • react-native-safe-area-context → "A flexible way to handle safe area", is something like a better version of SafeAreaView;
  • redux → "A Predictable State Container for JS Apps";
  • react-redux → Integration of redux to Reacts applications;
  • redux-logger → Allows to log the changes that is made in the redux state (display actions dispatches and store changes in browser console);
  • redux-thunk → Intercept an action and handle with it's behavior and results;
  • styled-components → Have a clean code with native css styling creating custom natives components;
  • yup → Validation JS tool to improve the use of Formik library;

🙏 How to use it

It's simple, just run the command bellow on your workspace directory:

npx react-native init MyProjectName --template react-native-template-alecpo

🗂 The folder hierarchy explanation

⚠️ This topic only describes that folders and files that diverges from the original React Native template.

alecpo-template
├── src/
│   ├── assets/ # Use this folder to storage any kind of assets required by your app.
│   │   └── img/ # Feel free to divide the images into subfolders .
│   │   └── svgAnimations/ # svg folder for animations (e.g: used by Lottie library)
│   ├── components/ # Put every kind of reusable custom components here.
│   │   └── DivisorLine.js # custom component to divide sections or elements in a list.
│   │   └── Icon.js # custom provided by react-native-vector-icons.
│   │   └── Label.js # custom text.
│   │   └── SubmitButton.js # custom submit button.
│   ├── config/ # Folder to the configurations files (e.g: API constants file, Reactotron, i18n, etc).
│   │   └── api.js # file to define the API's and endpoints constants.
│   ├── navigation/ # Folder for the "navigators" of React Navigation library. Use to structure the folder hierarchy. (Hint: Do this with advance planning).
│   │   └── RootStackNavigator.js # initial navigator of React Nativagation library.
│   ├── screens/ # Folder for ALL the screens files.
│   │   └── HomeScreen.js # Initial screen.
│   ├── store/ # Follow the structure to use Redux in your project.
│   │   └── actions/ # Action types and action creators files.
│   │   └── reducers/ # "Reducer's" files.
│   │   └── storeConfig.js # "store" settings file.
│   ├── utils/ # Helpers for your project.
│   │   └── customPropTypes/ # This folder contains the customs PropTypes that you probably will need.
│   │   └── enums/ # Enums folders.
│   │   └── colors.js # File to specify your application's color palette.
│   │   └── spacing.js # Generic pattern of spacings to your project.
│   │   └── strings.js # Strings constants used to prevent syntax mistakes and provide a scalable internationalization.
│   │   └── typography.js # Constants used to customize the "Label" component.
├── .prettierrc.json # Used to indent your project automatically.
├── babel.config.js # Allows you to use an alias on import custom modules or components (e.g: #/components/Label).
├── jsconfig.json # Offers autocomplete for your absolute path using alias (#/).
├── LICENSE # License file description.
└── README.md # Template documentation in markdown text.