Skip to Content
Vite

Vite

Installation

Follow the installation docs in the Introduction.

Usage

In any component, import Tweet from react-tweet and use it like so:

import { Tweet } from 'react-tweet' export const IndexPage = () => <Tweet id="2040511285998313827" />

You can learn more about Tweet in the Twitter theme docs.

Running the test app

Clone the react-tweet repository and then run the following command:

pnpm install && pnpm dev --filter=vite-app...

The app will be up and running at http://localhost:5173  for the Vite app example .

The app shows the usage of react-tweet in different scenarios:

The source code for react-tweet is imported from packages/react-tweet  and any changes you make to it will be reflected in the app immediately.

Last updated on