How to locate build output files of react app in Visual Studio 2022

Jiatong Zhu 0 Reputation points
2024-06-01T23:14:51.7633333+00:00

I created a "Standalone TypeScript React Project" in Visual Studio 2022.

The project could be run successfully by pressing F5 key.

I tried building the solution by clicking "Build -> Build Solution"

After building, I cannot locate the files that should have been produced by the build operation.

How can I find the files?

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
5,193 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Gowtham CP 5,210 Reputation points
    2024-06-02T18:40:49.9333333+00:00

    Hello Jiatong Zhu ,

    Thank you for reaching out on the Microsoft Q&A .

    To locate your React app's build output in Visual Studio 2022, follow these steps:

    First, open up File Explorer and head to your project folder. Look out for the build folder inside – that's where all the important files like index.html, static assets, and JavaScript bundles reside.

    Now, if you're up for it and want to tweak the output location:

    Simply right-click on your project in Visual Studio's Solution Explorer, then click on "Properties." From there, navigate to the "Build" section where you'll find the "Output path" property. Adjust it to your liking and hit "OK" to save your changes.

    I hope this helps! If you have any further questions, feel free to ask.

    If the information is useful, please accept the answer and upvote it to assist other community members.


  2. Bruce (SqlWork.com) 66,706 Reputation points
    2024-06-02T20:04:29.7233333+00:00

    vs 2002 uses a node project for standalone react apps (even when compiled with core). the key to the node project is the package.json file, which defines the build command under the "scripts" section. if you used a current template it use vite to build the app. vite by default writes to the /dist folder, but this can be overridden in build command.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.