madskristensen / WebEssentials2013

Visual Studio extension
http://vswebessentials.com
Other
944 stars 251 forks source link

Bad image path in SASS files #1720

Open santypr opened 9 years ago

santypr commented 9 years ago

For the last weeks I'm experiencing a big problem when I write an image url in a SASS file. The compiler y changing the path to an absolute path so the system cant't find the image.

Original in SASS file background-image: url(../Images/Icons/search-magenta-32.png);

Compiled CSS file background-image: url(D:\Development\myexample\mvc\Content\Images\search-magenta-32.png);

I've tested using '' and without them

am11 commented 9 years ago
  1. Which version of WE (or node-sass to be precise if you can dig it up**) is that?
  2. Do you get the same results if Autoprefixer and RTLCss are disabled under Tools > Options > Web Essentials > CSS?

\ There is a nodejs executable, where WE is installed: %LocalAppData%\Microsoft\VisualStudio\12.0\Extensions\<some-unique-hash-code>\Resources\nodejs\node.exe. Open cmd or PowerShell, enter this directory using cd and run this command: node tools\node_modules\node-sass\bin\node-sass --version.

santypr commented 9 years ago

It doesn't work. If I use relative path the compiler converts the path to an absolute system path

am11 commented 9 years ago

You didn't answer the questions though..

santypr commented 9 years ago

My version is 3.5 and I updated yesterday with the nightly build to 3.5.1 and the result is the same with Autoprefixer and RTLCSS disabled :(

am11 commented 9 years ago

You project is D: drive. That is probably not the system drive. If that is the case, do you get the same result when the project is in system (C:) drive?

santypr commented 9 years ago

D: is my secondary HD. The problem persists if I change the project to C:

am11 commented 9 years ago

Wait, are you using WE2013 with VS2013? :)

Because WE2013's latest version is 2.5.3.

santypr commented 9 years ago

That's right, I write the numbers in wrong order. My version is 2.5.3.1 as you can see in the screenshot we

rockstardev commented 9 years ago

+1 Same problem here