Napping Panda Missionaries

    sort-package-deps

    1.0.10 • Public • Published

    sort-dependencies

    npx sort-dependencies <path-to-package-dir-or-package.json> --apply

    Why

    Some toolchains like @microsoft/rush or pnpm make changes to package.json dependencies without keeping the alphabetical order. This can also happen when doing manual changes of course.

    The problem arises when tools like pnpm publish in combination with rush then sort the dependencies alphabetically but don't commit it back leaving a dirty repo which causes pnpm to abort publishing.

    sort-dependencies is thus useful in

    I also could somehow not find another package that did this the way I liked. prettier-package-json was close but did way more and also reordered the the root properties themselves which I did not like.

    Install

    npm i sort-package-deps

    DownloadsWeekly Downloads

    25

    Version

    1.0.10

    License

    MIT

    Unpacked Size

    1.34 MB

    Total Files

    13

    Last publish

    Collaborators

    • matthiasg