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

@karthickumarelumalai/rn-basic-setup

v1.0.15

Published

basic setup

Downloads

1

Readme

A basic setup for React Native applications.

Installation

To install this package, run the following command:

npm install @karthickumarelumalai/rn-basic-setup

Components

This package includes the following components:

CustomButton:

import React from 'react';
import { CustomButton } from '@karthickumarelumalai/rn-basic-setup';

const App = () => {
  return (
    <View>
      <CustomButton text="Click me!" onPress={() => console.log('Button pressed!')} />
    </View>
  );
};

CustomImage:

import React from 'react';
import { CustomImage } from '@karthickumarelumalai/rn-basic-setup';

const App = () => {
  return (
    <View>
      <CustomImage source={{ uri: 'https://example.com/image.jpg' }} style={{ width: 100, height: 100 }} />
    </View>
  );
};

CustomInput:

import React, { useState } from 'react';
import { CustomInput } from '@karthickumarelumalai/rn-basic-setup';

const App = () => {
  const [text, setText] = useState('');

  return (
    <View>
      <CustomInput
        placeholder="Enter some text"
        value={text}
        onChangeText={(text) => setText(text)}
        style={{ width: 200, height: 40 }}
      />
    </View>
  );
};

CustomText:

import React from 'react';
import { CustomText } from '@karthickumarelumalai/rn-basic-setup';

const App = () => {
  return (
    <View>
      <CustomText text="Hello, world!" style={{ fontSize: 24, color: 'blue' }} />
    </View>
  );
};

CustomFlatList:

import React from 'react';
import { CustomFlatList } from '@karthickumarelumalai/rn-basic-setup';

const App = () => {
  const data = ['Item 1', 'Item 2', 'Item 3'];

  return (
    <View>
      <CustomFlatList
        data={data}
        renderItem={({ item }) => <CustomText text={item} />}
        style={{ width: 200, height: 200 }}
      />
    </View>
  );
};

CustomRadioButton:

import React, { useState } from 'react';
import { CustomRadioButton } from '@karthickumarelumalai/rn-basic-setup';

const App = () => {
  const [selected, setSelected] = useState(false);

  return (
    <View>
      <CustomRadioButton
        selected={selected}
        onPress={() => setSelected(!selected)}
        style={{ width: 20, height: 20 }}
      />
    </View>
  );
};

CustomLoadingScreen:

import React, { useState } from 'react';
import { CustomLoadingScreen } from '@karthickumarelumalai/rn-basic-setup';

const App = () => {
  const [visible, setVisible] = useState(true);

  return (
    <View>
      <CustomLoadingScreen visible={visible} style={{ width: 200, height: 200 }} />
    </View>
  );
};

CustomApi: Created using Axios getRequest and postRequest

// Example of a GET request

const getData = async () => {
    try {
      const response = await getRequest("YOUR BASE URL","END POINT");
      console.log("Get Response:",response)
    } catch (error) {
      console.error(error);
    } 
  };
// Example of a POST request

const postData = async () => {
    const payload = { key: "value" }; // Your payload data
    try {
      const response = await postRequest("YOUR BASE URL","END POINT", payload);
      console.log("Post Response:", response);
    } catch (error) {
      console.error(error);
    } 
  };

Author

Karthic_Kumar_Elumalai

Github

https://github.com/Karthickumar1006/react-native-custom-components