Live Sass Compiler causing Extension Host crash after latest VSCode - html

I am trying to use sass styling and Live Sass Compiler extension, I recently installed it and now keep getting a extension host terminated unexpectedly error using VS Code.I have re-installed Live Sass Compiler several times as well as all my Live extensions and restarted my VS Code. Live Extensions I've re-installed. I know its the Live Sass Compiler causing this issue, because once I uninstall, I don't see the error anymore, but I can't update any styling in my . scss files. Everything is up to its current version.
How can I keep using Sass if this extension isn't working? Sass extension error Thank you!

This has been bothering me for so bloody long... Turns out (for me anyway) it was the extension "Color Highlight" that was causing it to crash. I'm going to be very careful downloading random extensions in the future..

for my situtation it blocks me only when I import a partial scss file so disabled it and only enable it when i have no more partial files to import.
color highlight is very useful for me.
or you can use the npm module "node-sass" with the flag -w

This is the exact issue I'm facing currently while using the "Live Sass Compiler". Whenever I try to edit any "#import" lines it just gives me the error.
See this image ... Extension host termination error!
Problem:
I'm facing this issue only while using the "Live Sass Compiler" as you can see in the screenshot ... Error in detail. This is similar to the one you're getting.
Quick Fix:
There must be some interruptions in the process due to which the extension is causing this error. Now, continue using the sass compiler and getting rid of that error I would suggest you uninstall the "Live Sass Compiler" and instead use npm install node-sass --save-dev to install the node-sass compiler as a dependency. Now in package.json enter the required script for node-sass to run.
This will allow you to compile .scss files to css. For more info checkout this link "https://www.npmjs.com/package/node-sass".
Hope you got your answer,
Cheers!

Related

Angular 2 RC5 webpack source maps misaligned for debugging

Since upgrading to RC5, when debugging in Chrome dev tools, breakpoints are hit, but the debugger identifies the line as several to many lines later (in this case 15 lines!). In the screenshot the "current" line is actually the line where debugger; is present. This is making debugging very difficult. This is in combination with webpack. It works, but you have to interpret things manually rather than seeing exactly which line is executing. It appears to only do this on my ts files, not on the angular code if I debug into it.
I'd love ideas on the source of this problem and how to fix it.
Chrome 52
webpack 1.13.1 with config.devtool = "source-map"
If you set config.devtool to eval all is correct. But any other value seems to have the offset issue.
Angular 2 RC5
I was facing the same problem. The solution that was given to me was to uninstall the npm version of the angular-cli and reinstall the Github one by running the following:
npm uninstall --save-dev angular-cli
and then
npm i --save-dev github:angular/angular-cli#a8d7c0a9a0c1657db2a673c42bfbaa51fde2a466

How do I use electron-compile?

I'm having trouble with electron-compile.
The docs state
How does it work? (Easiest Way)
Change your reference to electron-prebuilt to electron-prebuilt-compile. Tada! You did it.
What reference, where? You can't be talking about package.json?
I've always run electron using supervisor -x "electron" -i "./" .
What am I completely missing / what should be the contents of my pull request to make this clearer?
I've installed electron-compile with npm i electron-compile --save-dev
I'd like to have es2015/jsx precompiled to es5, so that I can run a react application in electron. electron-compile appears to solve this problem.
You should install Electron as a dev reference in package.json, yes:
npm install --save-dev electron-prebuilt-compile
Don't install Electron as a global because then other people have to set stuff up to run your app (i.e. they now have to micromanage which version of Electron they have installed globally)
With the recent versions (electron 1.3.5), I was unable to get electron-prebuilt-compile working, well it works for development but packaging for production has no real working examples.
It seems the compiling and packaging needs to be done manually, so in case anyone needs a working example, it's here. Hope to save someone some time and pain.

Visual Studio 2015 - Where's the gulp task runner?

I heard Mads Kristensen in his videos mention that Gulp and Grunt are both first class citizens. I thought I even heard mention of the Gulp task runner.
But when I create a gulpfile and right click there's no task runner.
Has anyone been able to get the "native" gulp task runner (if there is one) in Visual Studio 2015 Preview to appear?
View > Other Windows > Task Runner Explorer and click refresh
or just Ctrl + Alt + Bkspace
The Preview version of VS2015 requires Gulp to be installed globally and has a few other issues with auto-discovery of the gulpfile.js. These issues will all be addressed by the time VS2015 ships.
I had this same problem with VS2015 - TRX was showing "no tasks found" even though I had a valid, linted, gulpfile.js in the site root. I found the answer here: http://www.roelvanlisdonk.nl/?p=4258
Steps: Close VS. Open a cmd prompt from the site root and run npm install. Re-open VS and you should see your tasks in TRX. It worked for me.
EDIT: I had gulp installed globally but still encountered this "error." The above steps resolved the issue though.
Well I solved the problem with several restarts of VS2015. Finally the task runner appeared for my gulpfile. I still have no idea why it did not appear from the start but it's a preview version so maybe something is not quite right yet.
Barryman9000's answer helped me on the right track. I started with an empty ASP.NET 5 project in VS2015 and had no package.json file at the project root. Running npm install gave me an error message about missing package.json. After adding that file with the default dependencies from another ASP.NET 5 project, the Dependencies started downloading and my gulpfile tasks appeared in the Task Runner Explorer.
In your bash, go to the directory gulpfile.js is installed in and run:
npm install gulp
Why the downvotes? Please read the OP's question and the comments beneath it. Also, note that the answer with, currently, the most points has nothing to do with the question. Also please note that Mads Kristensen himself said that the issue was to install gulp.
Also, as for the commenter "Bonner" of this answer, note that Bash doesn't mean Linux. You can install git bash for Windows and run all of your NPM and Git commands there. Most developers I know use that bash on windows for all npm needs.
Lastly, if your Gulp Task Runner is not working, that is most likely because it is not recognizing your gulpfile. That is due to gulp not being installed. VS2015 didn't always install gulp for you. So the fix was to install gulp globally (As Mads Kristensen said), or directly where your gulpfile is. Also, restarting or re-installing VS sometimes kickstarted the gulp installation if you're lucky.
Conclusion: My answer is the correct answer. I reference the actual OP Question, comments beneath it, Mads Kristensen, and even the accepted answer. Yet, this answer is in the negative and some random answer about how to use the "View" menu in Visual Studio has 40 points.

Gruntfile not found

I am trying to use Sublime Text 2 with Grunt, but I can't get it working.
The watch task is working if I do it on the Windows console (so it is installed correctly), but not in ST, there it says "Gruntfile.js or Gruntfile.coffee not found" (using the Grunt plugin).
I have no idea why, because there is a folder called "build" containing the Gruntfile.js and the other stuff in the project directory.
I tried removing ST and the plugin and installed it again, but still the same problem.
Any ideas?
Gruntfile should be at the root of the project.
http://gruntjs.com/getting-started#the-gruntfile
You can see the exact code that's throwing the error here: https://github.com/tvooo/sublime-grunt/blob/master/main.py#L41

Sublime Linter not working in Windows

As the title says.
The linter doesnt seem to work at all for me in Windows. I have tried it with javascript and php files with the correct syntax set.
Im following Jeffery Ways tutorial here -> https://tutsplus.com/lesson/sublime-linter/
I have installed package control,
SublimeLinter and nothing, removed it
installed sublimelinter beta and nothing too.
Any help please
From SublimeLinter's github page:
"If you plan to edit files that use a Javascript-based linter (Javascript, CSS), your system must have a Javascript engine installed... On Windows, you must install the Javascript engine Node.js, which can be downloaded from the Node.js site."
Node.js
Install it like a normal Windows application. Close Sublime and restart. Linting should be working.
You need to point the SublimeLinter to your PHP executable file in the SublimeLinter.sublime-settings.
Change this option:
"sublimelinter_executable_map":
{
"php": "C:\\wamp\\bin\\php\\php5.3.13\\php.exe"
},
Edit:
See this link for more help
http://fuzzytolerance.info/blog/2012/05/14/2012-05-15-getting-sublimelinter-running-on-windows/
In order to get SublimeLint linting js files, I had to follow the instructions here and install this additional plugin:
(I didn't need to follow the 'Linter configuration' step)
https://github.com/SublimeLinter/SublimeLinter-jshint#linter-installation