Introduction to TypeScript with React

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • axios

    Promise based HTTP client for the browser and node.js

  • So let's first install the axios npm library, so we can make an API call using it.

  • vite

    Next generation frontend tooling. It's fast!

  • Now, we will create a Vite project using TypeScript.

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
  • react-typescript-demo

    Introduction to TypeScript with React

  • You can find the complete source code for this application in this repository.

  • Randomuser.me-Node

    Source code that powers randomuser.me

  • import axios from 'axios'; import { FC, useState } from 'react'; import { AppProps, Users } from './App.types'; import User from './components/User'; const App: FC = ({ title }) => { const [users, setUsers] = useState([]); const [isLoading, setIsLoading] = useState(false); // useEffect(() => { // const getUsers = async () => { // try { // setIsLoading(true); // const { data } = await axios.get( // 'https://randomuser.me/api/?results=10' // ); // console.log(data); // setUsers(data.results); // } catch (error) { // console.log(error); // } finally { // setIsLoading(false); // } // }; // getUsers(); // }, []); const handleClick = async () => { try { setIsLoading(true); const { data } = await axios.get('https://randomuser.me/api/?results=10'); console.log(data); setUsers(data.results); } catch (error) { console.log(error); } finally { setIsLoading(false); } }; return (

    {title}

    Show Users {isLoading &&

    Loading...

    }
      {users.map(({ login, name, email }) => { return ; })}
    ); }; export default App;

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts