node-sass size after upgrading to Node 11.1 with build-tools on windows
initially I was using Node v10 (I believe) and when generating a new angular project (v7) my node_modules were a "modest" ~140 Mb.
I then decided to upgrade to Node v11.1 and install the build-tools, that the installer now optionally allows you to install.
My node_modules size went to over 700 MB.
The culprit is the node-sass package, which is now downloading the whole project (cpp files, .sln and all) and getting fully compiled on the initial npm install (using node-gyp).
Is there any way to change this behavior to the way it did things without the installed build tools? (short of manually uninstalling the build pipeline that node automatically installed)
Or is there any advantage that I'm not seeing? To me it all worked just fine (including everything scss and sass-related) without the huge increase in occupied space.
node.js angular node-gyp node-sass
add a comment |
initially I was using Node v10 (I believe) and when generating a new angular project (v7) my node_modules were a "modest" ~140 Mb.
I then decided to upgrade to Node v11.1 and install the build-tools, that the installer now optionally allows you to install.
My node_modules size went to over 700 MB.
The culprit is the node-sass package, which is now downloading the whole project (cpp files, .sln and all) and getting fully compiled on the initial npm install (using node-gyp).
Is there any way to change this behavior to the way it did things without the installed build tools? (short of manually uninstalling the build pipeline that node automatically installed)
Or is there any advantage that I'm not seeing? To me it all worked just fine (including everything scss and sass-related) without the huge increase in occupied space.
node.js angular node-gyp node-sass
You could contribute a built binary back to node-sass or wait for them to update with one. I think it will go down on it's own once that happens.
– Dominic
Nov 16 '18 at 9:27
add a comment |
initially I was using Node v10 (I believe) and when generating a new angular project (v7) my node_modules were a "modest" ~140 Mb.
I then decided to upgrade to Node v11.1 and install the build-tools, that the installer now optionally allows you to install.
My node_modules size went to over 700 MB.
The culprit is the node-sass package, which is now downloading the whole project (cpp files, .sln and all) and getting fully compiled on the initial npm install (using node-gyp).
Is there any way to change this behavior to the way it did things without the installed build tools? (short of manually uninstalling the build pipeline that node automatically installed)
Or is there any advantage that I'm not seeing? To me it all worked just fine (including everything scss and sass-related) without the huge increase in occupied space.
node.js angular node-gyp node-sass
initially I was using Node v10 (I believe) and when generating a new angular project (v7) my node_modules were a "modest" ~140 Mb.
I then decided to upgrade to Node v11.1 and install the build-tools, that the installer now optionally allows you to install.
My node_modules size went to over 700 MB.
The culprit is the node-sass package, which is now downloading the whole project (cpp files, .sln and all) and getting fully compiled on the initial npm install (using node-gyp).
Is there any way to change this behavior to the way it did things without the installed build tools? (short of manually uninstalling the build pipeline that node automatically installed)
Or is there any advantage that I'm not seeing? To me it all worked just fine (including everything scss and sass-related) without the huge increase in occupied space.
node.js angular node-gyp node-sass
node.js angular node-gyp node-sass
asked Nov 15 '18 at 20:56
JejuniJejuni
214
214
You could contribute a built binary back to node-sass or wait for them to update with one. I think it will go down on it's own once that happens.
– Dominic
Nov 16 '18 at 9:27
add a comment |
You could contribute a built binary back to node-sass or wait for them to update with one. I think it will go down on it's own once that happens.
– Dominic
Nov 16 '18 at 9:27
You could contribute a built binary back to node-sass or wait for them to update with one. I think it will go down on it's own once that happens.
– Dominic
Nov 16 '18 at 9:27
You could contribute a built binary back to node-sass or wait for them to update with one. I think it will go down on it's own once that happens.
– Dominic
Nov 16 '18 at 9:27
add a comment |
1 Answer
1
active
oldest
votes
So, I found out what's going on.
The current version of angular (cli version 7.0.6) installs node-sass at version 4.9.3.
Version 4.9.3 does not support node v11. Support for node v11 was added with 4.10.0. As such the install script that node-sass is running can't find a pre-built binary to download from github and falls back to building the source files (which results in 400 MB wasted space).
That's why the problem started cropping up after I updated to the latest node version.
For now there's 2 solutions:
- Stick with LTS v10 of node (for which there is a pre-built binary)
- Manually upgrade to the latest version of node-sass and hope angular doesn't break because of it
I went with option 1 and installed the LTS node version.
This is a problem that will probably fix itself in time, as angular updates its node-sass dependency. For the time being I hope the answer will help someone facing the same situation.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53327785%2fnode-sass-size-after-upgrading-to-node-11-1-with-build-tools-on-windows%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
So, I found out what's going on.
The current version of angular (cli version 7.0.6) installs node-sass at version 4.9.3.
Version 4.9.3 does not support node v11. Support for node v11 was added with 4.10.0. As such the install script that node-sass is running can't find a pre-built binary to download from github and falls back to building the source files (which results in 400 MB wasted space).
That's why the problem started cropping up after I updated to the latest node version.
For now there's 2 solutions:
- Stick with LTS v10 of node (for which there is a pre-built binary)
- Manually upgrade to the latest version of node-sass and hope angular doesn't break because of it
I went with option 1 and installed the LTS node version.
This is a problem that will probably fix itself in time, as angular updates its node-sass dependency. For the time being I hope the answer will help someone facing the same situation.
add a comment |
So, I found out what's going on.
The current version of angular (cli version 7.0.6) installs node-sass at version 4.9.3.
Version 4.9.3 does not support node v11. Support for node v11 was added with 4.10.0. As such the install script that node-sass is running can't find a pre-built binary to download from github and falls back to building the source files (which results in 400 MB wasted space).
That's why the problem started cropping up after I updated to the latest node version.
For now there's 2 solutions:
- Stick with LTS v10 of node (for which there is a pre-built binary)
- Manually upgrade to the latest version of node-sass and hope angular doesn't break because of it
I went with option 1 and installed the LTS node version.
This is a problem that will probably fix itself in time, as angular updates its node-sass dependency. For the time being I hope the answer will help someone facing the same situation.
add a comment |
So, I found out what's going on.
The current version of angular (cli version 7.0.6) installs node-sass at version 4.9.3.
Version 4.9.3 does not support node v11. Support for node v11 was added with 4.10.0. As such the install script that node-sass is running can't find a pre-built binary to download from github and falls back to building the source files (which results in 400 MB wasted space).
That's why the problem started cropping up after I updated to the latest node version.
For now there's 2 solutions:
- Stick with LTS v10 of node (for which there is a pre-built binary)
- Manually upgrade to the latest version of node-sass and hope angular doesn't break because of it
I went with option 1 and installed the LTS node version.
This is a problem that will probably fix itself in time, as angular updates its node-sass dependency. For the time being I hope the answer will help someone facing the same situation.
So, I found out what's going on.
The current version of angular (cli version 7.0.6) installs node-sass at version 4.9.3.
Version 4.9.3 does not support node v11. Support for node v11 was added with 4.10.0. As such the install script that node-sass is running can't find a pre-built binary to download from github and falls back to building the source files (which results in 400 MB wasted space).
That's why the problem started cropping up after I updated to the latest node version.
For now there's 2 solutions:
- Stick with LTS v10 of node (for which there is a pre-built binary)
- Manually upgrade to the latest version of node-sass and hope angular doesn't break because of it
I went with option 1 and installed the LTS node version.
This is a problem that will probably fix itself in time, as angular updates its node-sass dependency. For the time being I hope the answer will help someone facing the same situation.
edited Nov 18 '18 at 10:32
nschonni
1,9451626
1,9451626
answered Nov 16 '18 at 9:23
JejuniJejuni
214
214
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53327785%2fnode-sass-size-after-upgrading-to-node-11-1-with-build-tools-on-windows%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
You could contribute a built binary back to node-sass or wait for them to update with one. I think it will go down on it's own once that happens.
– Dominic
Nov 16 '18 at 9:27