Please visit angular.dev to see this page for the current version of angular Compiles an angular application or library into an output directory named dist/ at the given output path The command can be used to build a project of type application or library. The result of this build process is output to a directory (dist/${project_name} by default). Define your size boundaries in the cli configuration file, angular.json, in a budgets section for each configured environment. The option enables you to specify the full path to the new output directory.
Angular team has updated the angular cli design to always output publicly accessible files in browser directory and the ssr files in server directory and other files such as statistics and licenses information in the root output path. Both ng build and ng serve clear the output folder before they build the project, but only the ng build command writes the generated build artifacts to the output folder To output to a different folder, change the outputpath in angular.json. Now that you are finished developing your application, you can run the angular cli build command When you run the build command in your todo directory, your application compiles into an output directory named dist/. The angular cli uses the tsconfig paths to tell the build system where to find the library
The application builder uses the esbuild build tool, with default configuration options specified in the workspace configuration file (angular.json) or with a named alternative configuration. The cli already does this, that's what ng build is for
OPEN