Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

But why...? #6

Closed
einthusan opened this issue Oct 6, 2014 · 8 comments
Closed

But why...? #6

einthusan opened this issue Oct 6, 2014 · 8 comments

Comments

@einthusan
Copy link

I don't get it... is this some project to show that Go can be used to do such things or was this really solving a pain point...? Why not just use execute an external program like lessc? Usually compiling from the sever side is done just once.. so am I missing something?

@Ghoughpteighbteau
Copy link

Yes, compiled CSS options depend on ruby or node.js

If your server doesn't depend on either, and you want to use a compiled CSS language, that's painful. Your options are to compile in the development phase, or bite the bullet and include these dependencies.

More over, where's your sense of adventure, man!

@yosssi
Copy link
Owner

yosssi commented Oct 7, 2014

Thanks for your comments! I wanted to compile an alternate CSS file like Less per HTTP request in Go HTTP server in development mode without any external libraries, and created this package.

@einthusan
Copy link
Author

I would of been happier if the syntax was similar to Less instead of Sass lol.

I kinda wish you enforced the { } braces just like how Go enforces them... Feels more consistent.

In any case, do you plan on making it production ready... ? Also, you (or someone in the community) will probably have to remove all my other dependencies on nodejs to actually make it worthwhile... for instance uglify-js, html-minifier, and clean-css... then I really don't need to install nodejs :)

Sorry I was a bit rude to begin with.. At least your contributing where I'm just complaining!!

@einthusan
Copy link
Author

@yosssi Oh that makes sense... may I know your use case for why you need to compile for each request?

@yosssi
Copy link
Owner

yosssi commented Oct 7, 2014

@einthusan

I would of been happier if the syntax was similar to Less instead of Sass lol.

I kinda wish you enforced the { } braces just like how Go enforces them... Feels more consistent.

Oh, you like the style of Less... I omitted curly braces and semicolons from the GCSS syntax for making the syntax simple. I think it's a matter of taste.

In any case, do you plan on making it production ready... ?

Yes, I do. I'm going to release version 1.0 (production version) of this package near the end of the year if any issues would not occur until then.

Also, you (or someone in the community) will probably have to remove all my other dependencies on nodejs to actually make it worthwhile... for instance uglify-js, html-minifier, and clean-css... then I really don't need to install nodejs :)

That's a good idea. We have to do a lot of things to remove all dependencies!

Sorry I was a bit rude to begin with.. At least your contributing where I'm just complaining!!

No prob. It was my fault because I didn't say why I started to create this package at all.

may I know your use case for why you need to compile for each request?

When I develop a Go web app, I want to compile GCSS files for each request because I can save the time to execute a compile command and restart an HTTP server process. I know I can do it by using the Grunt's watch task but I don't rely on using Node.js when I develop a Go application.

@einthusan
Copy link
Author

@yosssi Thanks for the awesome reply. 👍 I just want to warn you that doing compilation on each http request will significantly hurt your req/sec performance... try boom or wrk to test your req/sec scenario for pre-compile vs on-demand compile ... pretty sure you will see huge differences in how many requests you can serve. In fact, if you see that there isn't much of a performance issue, maybe you can post those results in your readme file or here. Thanks!

@yosssi
Copy link
Owner

yosssi commented Oct 8, 2014

@einthusan Thanks for your advice. Yeah, I'll compile a GCSS file for each request only in development mode. I'll use a pre-compiled CSS file in production.

@einthusan
Copy link
Author

Oh lol... I didn't know you were doing that.. Well then.. thanks for the chat.. I will mark this as closed! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants