Is there a postcss plugin which compiles scss to css(gulp)? - plugins

For example, postcss-scss is not a plugin but a parser, which does not compile scss to css. I know there is a gulp-sass and it works just fine.
The reason I would like to start using a plugin for postcss is because they say postcss can be more than 30 times faster.
But it seems I can't find a plugin for postcss which would compile scss to css. Please, help.

Be aware that PostCSS shouldn't be used together with SCSS in one workflow routine as this pretty much defeats its purpose. It's either SCSS to CSS or PostCSS to CSS.
As you already stated, there is a postcss-scss parser, but that serves the purpose of using SCSS syntax when working with PostCSS:
PostCSS can transform styles in any syntax, not just CSS.

Related

How can I edit in indented SASS but commit in SCSS?

I'm a fan of the clean, Pythonesque feel of indented SASS, but I recognize that it's better for my team to use SCSS since it's an extension of CSS, and there's more support for SCSS in docs and forums. So how might I view and edit files as SASS but commit them as SCSS?
Checkout .scss files from a repo
Open them in an editor and see indented SASS
Make changes in indented SASS
Commit changes as .scss
I expect that it's possible since, as one of the developers who helped create Sass wrote,
The difference is syntax. Underneath the textual exterior they are identical. This is why sass and scss files can import each other. Actually, Sass has four syntax parsers: scss, sass, CSS, and less. All of these convert a different syntax into an Abstract Syntax Tree which is further processed into CSS output or even onto one of the other formats via the sass-convert tool.
Use the syntax you like the best, both are fully supported and you can change between them later if you change your mind.
I'm using VSCode, and I've looked through dozens of extensions and linters, but I haven't found any that appear to offer this feature. Reasons why this is a bad idea are welcome if they're in good faith or good fun.

Auto-suggestion HTML and CSS code without an extension in VS Code

I just installed Visual Studio Code. It works and suggests HTML and stylesheet and JavaScript as well, but what matters is that I didn't install any extension in Visual Studio Code, and it works well without HTML and JavaScript extension.
How does it work without any extension? Do I need to install an extension for this?
To answer it on Low-Level, VS Code is built on top of monaco-editor
As mentioned in its docs, it has below stuffs by default
Rich IntelliSense, Validation TypeScript, JavaScript, CSS, LESS, SCSS,
JSON, HTML
Refer: https://microsoft.github.io/monaco-editor/
Those shortcut features are built with https://emmet.io/
So, for working with basic web stuffs, you don't need an extension.

Visual Studio Code suggestions and autoclose are not working

I have some issues with my Visual Studio Code. After installing a fresh copy of it, and cleaned all the items stored by it, the autoclose plugin, the suggestion plugins are not working at all. All autosuggestions are prefixed by the icon [abc], the wrench key or blank file.
List of my plugins:
Angular 2 TypeScript Emmet
Angular 2 TypeScript Test Snippets
Angular 2+ Snippets - TypeScript, Html, ngRx, Angular Flex Layout, Material & Testing
Angular Files
Angular CLI
Angular v4 TypeScript Snippets
Auto Close tag
Auto Import
Beautify
Beautify CSS/sass/scss/less
CSS Peak
Debugger for Chrome
File Peek
Find all references
Highlight matching taf
HTML CSS Support
IntelliSense for CSS class
JavaScript ES6 code snippet
JavaScript and TypeScript IntelliSense
JavaScript Snippet Pack
jQuery Code Snippets
jslint
Less IntelliSense
Path IntelliSense
PHP IntelliSense
Prettify JSON
Stylesheet Formatter
Twig
TWIG pack
And all of them looks like something is not working. Here are some example of this issue:
Thanks!

Why JSX Transform is deprecated? What is the advantage of using Babel over JSX transform?

Since i have started reading react, I learnt about JSX and Babel. Before Babel, JSX transformer [React tools] were used to convert JFX syntax to browser understandable format. Now Babel takes over its place. My point is , Why they replaced JFX transformer? Does it had any disadvantages?
Well Babel has advantages such as being able to integrate with a variety of other tools, and being able to compile ES6 code. There was a post by FB here:
https://facebook.github.io/react/blog/2015/06/12/deprecating-jstransform-and-react-tools.html
And there's a few articles scattered around if you Google. Basically a lot of webapps use Babel, it's awesome and does JSX transformation as well as all the other JS compiling

LESS css or SCSS in GWT

Has anyone been able to integrate the wonderful shorthanded syntax of LESS with the awesomely module, re-factor friendly and type-safe CSS of GWT UiBinder?
<ui:style with="com.lesscss.gwt">
.selector{
/* Can I haz LESS in here? */
}
</ui:style>
Naturally, you can use LESS with GWT -- You just have to use non-compiled css. I want my css to go through the LESS compiler, and then the GWT compiler.
There are no direct libraries for that, no.
LESS doesn't even have a java compiler, so I really don't think it's ever going to happen.
Suppose you could write a pre-compile routine that will go through your ui.xml files, compile contents of ui:style nodes and put the compiled versions back. Then you will run into continuous problems with your IDE complaining about improper CSS code.
As said before, there was no libraries to do that directly. But there is now ;) !
I recently wrote and published a library (HexaCss for GWT) which allows to bind a GWT application to external CSS files, while keeping type-safety and optimizations like pruning and css name obfuscation.
You use it like the traditionnal CssResource (so typesafely), but instead of binding to a CSS file Inside your GWT project, it binds to any external CSS file that you want (you can even bind multiple CSS files to the same application which gives you themes for your GWT application).
So in your case, the external CSS file would have been generated with HexaCss. That's what I do on many projects.
You can even use Sass, GSS and so on. You can also use the already written bindings for Bootstrap and Skeleton.
A sample which resembles to your question is this one, where the CSS is generated with Less, and used in GWT with HexaCss, which is then usable from UiBinder or Java directly.
Link to the sample : http://lteconsulting.fr/hexacss/demo/sample3/index.html - This is a very ugly demo showing only the idea. You can switch between themes with the listbox on the top.
Hope this helps !