[fix runtime error about starter-vite-tsc] ReferenceError: React is not defined
when I run "pnpm -C ./starter-vite-tsc/ run dev", server successfully start.
but in browser, error occured and nothing shows.
in console, "ReferenceError: React is not defined".
I solved this error by adding react plugin in vite.config.js
Pull Requests
We welcome contributions via pull requests! Here are some guidelines to help you get started:
- Fork the repository and clone it to your local machine.
- Create a new branch for your changes:
git checkout -b my-new-feature - Install dependencies:
pnpm install([email protected]) - Make your changes and add tests if applicable.
- Run the tests:
pnpm test - Create a changeset for your changes: before committing your changes, create a changeset to document the modifications. This helps in tracking and communicating the changes effectively. To create a changeset, run the following command:
pnpm changeset. - Commit your changes: after creating the changeset, commit your changes with a descriptive commit message:
git commit -am 'Add some feature'. - Push your changes to your fork:
git push origin my-new-feature. - Open a pull request against our
mainbranch.
Pull Request Guidelines
- Please make sure your changes are consistent with the project's existing style and conventions.
- Please write clear commit messages and include a summary of your changes in the pull request description.
- Please make sure all tests pass and add new tests as necessary.
- If your change requires documentation, please update the relevant documentation.
- Please be patient! We will do our best to review your pull request as soon as possible.
⚠️ No Changeset found
Latest commit: b8cb4a2aa13492f1c682cef38e9550e771f36359
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR