Skip to content

repositoryShorthand

Enforces using an object locator for repository.

✅ This rule is included in the package-json preset.

npm used to allow repository values to be provided as string values like this., The npm systems would normalize them to full objects behind-the-scenes on publish., npm no longer allows these kinds of differences between local package.json files and published contents.`,

This rule reports on any legacy repository shorthand string value, and fixes it to the normalized object form.

5<3{d ivclassNa="meec-li">nt< sp ansty="le--0:#7FDBCA;--1:#096E">72"repositor53<: sp ansty="le--0:#D9F5DD;--1:#1111">1<1"sp ansty="le--0:#C789D6;--1:#7C56">86flint-fyi/fli1<1"d ivclassNa="meec-li">5<3}d ivclassNa="meco"><}d>
3de6E72"reposit3F5<3: {divclass="Nameec-">dent< spans="tyle--0:#7FDBCA;--1:#09">6E72"t3F<53: spans="tyle--0:#D9F5DD;--1:#11">1<111" spans="tyle--0:#C789D6;--1:#7C">568<6git spans="tyle--0:#D9F5DD;--1:#11">1<111" spans="tyle--0:#D6DEEB;--1:#40">3dent< spans="tyle--0:#7FDBCA;--1:#09">6E72"3F<53: spans="tyle--0:#D9F5DD;--1:#11">1<111" spans="tyle--0:#C789D6;--1:#7C">5686https://github.com/flint-fyi/f1<111 "divclass="Nameec-">3F<53 spans="tyle--0:#D6DEEB;--1:#40">33< }>

If a package intentionally publishes under a different set of tooling than npm, your tooling may allow or even prefer repository shorthand. In that case this rule may not be for you.