nextcloud / website

An attempt to build a new website (obsolete)
7 stars 4 forks source link

SCSS to CSS build chain #1

Open MorrisJobke opened 6 years ago

MorrisJobke commented 6 years ago

Currently the CSS is the copy and paste from the existing compile CSS. We should include a SCSS to CSS step into the build chain. It's fine to not commit this to the repo here.

cc @Espina2 @jospoortvliet

Espina2 commented 6 years ago

@MorrisJobke @jospoortvliet please take a look on my pull request, I have written gulp tasks to handle that. You just run gulp watch and it will handle all the compilation for us. I will do the same for the javascript maybe I will use browserify so we can import functions from libraries without importing the whole library.

With this we have smaller build sizes.

MorrisJobke commented 6 years ago

Nice - exactly something like that. Also I would prefer to not ship assets from some CDNs but have everything available on the server.

MorrisJobke commented 6 years ago

ref #3

Espina2 commented 6 years ago

The only downside of this solution, is that in each deploy we have to compile the assets. So maybe we can improve this workflow with some automation tool, but not important for now. I just had one think I didn't find the right solution.

We should inline the svg's like in php, that will save us some http request's but I didn't fight a "right" way to do it. Any suggestion?

MorrisJobke commented 6 years ago

The only downside of this solution, is that in each deploy we have to compile the assets. So maybe we can improve this workflow with some automation tool, but not important for now. I just had one think I didn't find the right solution.

We will use an fully automated deployment. Don't worry about this.

MorrisJobke commented 6 years ago

We should inline the svg's like in php, that will save us some http request's but I didn't fight a "right" way to do it. Any suggestion?

Let's not do it for now. Let's ship it via own requests. Should be fine with HTTP2 and as it is pure asset serving it should also be fast for now. Don't optimise before we have a problem ;)

Espina2 commented 6 years ago

Its not an optimisation, if we inline the svgs we can manipulate them with css or js, if a request is needed you can't. ;)

MorrisJobke commented 6 years ago

Its not an optimisation, if we inline the svgs we can manipulate them with css or js, if a request is needed you can't. ;)

Ah - okay.

MorrisJobke commented 6 years ago

Is this really needed for a first version of the pages? I would at least remove some of the animations, because now I'm a bit overwhelmed by all the moving parts.

Espina2 commented 6 years ago

At the moment is needed so I can add an hamburguer menu and animate it with css. But I will find a solution. I have to put more time in this.

rullzer commented 6 years ago

They seem to have some suggestions for that in https://discourse.gohugo.io/t/embedding-inline-svg-in-content-markdown/7511/6