@@ -106,27 +106,39 @@ folder instead of the current working directory. See
106106* bin files are linked to ` {prefix}/bin `
107107* man pages are linked to ` {prefix}/share/man `
108108
109- #### ` global-style `
109+ #### ` install-strategy `
110+
111+ * Default: "hoisted"
112+ * Type: "hoisted", "nested", or "shallow"
113+
114+ Sets the strategy for installing packages in node_modules. hoisted
115+ (default): Install non-duplicated in top-level, and duplicated as necessary
116+ within directory structure. nested: (formerly --legacy-bundling) install in
117+ place, no hoisting. shallow (formerly --global-style) only install direct
118+ deps at top-level. linked: (coming soon) install in node_modules/.store,
119+ link in place, unhoisted.
120+
121+ #### ` legacy-bundling `
110122
111123* Default: false
112124* Type: Boolean
125+ * DEPRECATED: This option has been deprecated in favor of
126+ ` --install-strategy=nested `
113127
114- Causes npm to install the package into your local ` node_modules ` folder with
115- the same layout it uses with the global ` node_modules ` folder. Only your
116- direct dependencies will show in ` node_modules ` and everything they depend
117- on will be flattened in their ` node_modules ` folders. This obviously will
118- eliminate some deduping. If used with ` legacy-bundling ` , ` legacy-bundling `
119- will be preferred.
128+ Instead of hoisting package installs in ` node_modules ` , install packages in
129+ the same manner that they are depended on. This may cause very deep
130+ directory structures and duplicate package installs as there is no
131+ de-duplicating. Sets ` --install-strategy=nested ` .
120132
121- #### ` legacy-bundling `
133+ #### ` global-style `
122134
123135* Default: false
124136* Type: Boolean
137+ * DEPRECATED: This option has been deprecated in favor of
138+ ` --install-strategy=shallow `
125139
126- Causes npm to install the package such that versions of npm prior to 1.4,
127- such as the one included with node 0.8, can install the package. This
128- eliminates all automatic deduping. If used with ` global-style ` this option
129- will be preferred.
140+ Only install direct dependencies in the top level ` node_modules ` , but hoist
141+ on deeper dependendencies. Sets ` --install-strategy=shallow ` .
130142
131143#### ` omit `
132144
@@ -298,12 +310,12 @@ This value is not exported to the environment for child processes.
298310
299311#### ` install-links `
300312
301- * Default: false
313+ * Default: true
302314* Type: Boolean
303315
304- When set file: protocol dependencies that exist outside of the project root
305- will be packed and installed as regular dependencies instead of creating a
306- symlink. This option has no effect on workspaces.
316+ When set file: protocol dependencies will be packed and installed as regular
317+ dependencies instead of creating a symlink. This option has no effect on
318+ workspaces.
307319
308320### See Also
309321
0 commit comments