Skip to content

Conversation

@rosen-vladimirov
Copy link
Contributor

The old fix for installing only devDependencies before preparing the project has a problem:
npm install <devPackagesNames> does not respect the versions from the devDependencies section and always installs the latest versions.

We cannot use npm install <devPackageName>@<version> as we do not know if they are real versions or paths or even "frog legs".

There's a magical flag --dev which should allow you to do:
npm install <devPackagesNames> --dev and it will respect the versions from devDependencies. Unfortunately this flag forces recursive installation of devDependencies all down the tree of packages.

Of course npm has another rabbit in the hat - --only=dev. However I couldn't get it work at all.

So the only solution I could think about is to install all dependencies before preparing the project.

The old fix for installing only devDependencies before preparing the project has a problem:
`npm install <devPackagesNames>` does not respect the versions from the devDependencies section and always installs the latest versions.

We cannot use `npm install <devPackageName>@<version>` as we do not know if they are real versions or paths or even "frog legs".

There's a magical flag `--dev` which should allow you to do:
`npm install <devPackagesNames> --dev` and it will respect the versions from devDependencies. Unfortunately this flag forces recursive installation of devDependencies all down the tree of packages.

Of course npm has another rabbit in the hat - `--only=dev`. However I couldn't get it work at all.

So the only solution I could think about is to install all dependencies before preparing the project.
@rosen-vladimirov rosen-vladimirov self-assigned this Nov 13, 2015
@rosen-vladimirov rosen-vladimirov added this to the 1.5.0 milestone Nov 13, 2015
@teobugslayer
Copy link
Contributor

👍

@ns-bot
Copy link

ns-bot commented Nov 13, 2015

Test PASSed.

@Mitko-Kerezov
Copy link
Contributor

👍

1 similar comment
@Fatme
Copy link
Contributor

Fatme commented Nov 13, 2015

👍

rosen-vladimirov added a commit that referenced this pull request Nov 13, 2015
Install ALL dependencies and devDependencies before prepare
@rosen-vladimirov rosen-vladimirov merged commit 4b56f38 into release Nov 13, 2015
@rosen-vladimirov rosen-vladimirov deleted the vladimirov/fix-tsc-no-modules branch November 13, 2015 12:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants