Skip to content

Difference between ng build and npm run build #13560

@mdufoud1214

Description

@mdufoud1214

am using angular 7 and server side using .net core 2.1
if i do npm run build --prod --aot my dist folder size is around 40mb and my application working as expected,
but if i do ng build --prod --aot my dist folder size is reducing to around 9mb but am not able to run applications some map files are missing getting 404 error(find below screenshot)

i want reduce my bundle size to improve my angular app performance

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions