We have been using NGINX for a year now with great results, so thanks to
everyone who has made this project so successful!
I am looking for a feature which I hope NGINX supports, and that is
optimization of serving CSS files, specifically around minimizing and
resolving @import statements server side.
For instance, to better manage the hundreds of css files we have, we
started breaking them up and using the @import directive. Obviously this
slows things down quite a bit because the browser has to make lots of
additional requests.
I am looking for a way to have NGINX automatically resolve all @imports
so
when it servers a CSS file so it has no dependencies.
Any feedback would be much appreciated!
Thanks,
Casey
–
Casey J.
easyDITA a product of Jorsek LLC
“CaseyDJordan” on LinkedIn, Twitter & Facebook
(585) 348 7399
This message is intended only for the use of the Addressee(s) and may
contain information that is privileged, confidential, and/or exempt from
disclosure under applicable law. If you are not the intended recipient,
please be advised that any disclosure copying, distribution, or use of
the information contained herein is prohibited. If you have received
this communication in error, please destroy all copies of the message,
whether in electronic or hard copy format, as well as attachments, and
immediately contact the sender by replying to this e-mail or by phone.
Thank you.
Casey J.
easyDITA a product of Jorsek LLC
“CaseyDJordan” on LinkedIn, Twitter & Facebook
(585) 348 7399
This message is intended only for the use of the Addressee(s) and may
contain information that is privileged, confidential, and/or exempt from
disclosure under applicable law. If you are not the intended recipient,
please be advised that any disclosure copying, distribution, or use of
the information contained herein is prohibited. If you have received
this communication in error, please destroy all copies of the message,
whether in electronic or hard copy format, as well as attachments, and
immediately contact the sender by replying to this e-mail or by phone.
Thank you.
Thanks for the suggestion and we do already do this for a good deal of
our
application css.
The CSS I am talking about though is more dynamic, and is actually part
of
publishing pipelines that users of our software configure and use when
the
server is running. Users will be uploading new CSS, making changes etc,
all
in real time to influence published outputs of their content.
So it’s not ideal to compile this on deployment, which is a main reason
I
need a more dynamic solution.
files into a single file, and >make install< installs that into the
–
Casey J.
easyDITA a product of Jorsek LLC
“CaseyDJordan” on LinkedIn, Twitter & Facebook
(585) 348 7399
This message is intended only for the use of the Addressee(s) and may
contain information that is privileged, confidential, and/or exempt from
disclosure under applicable law. If you are not the intended recipient,
please be advised that any disclosure copying, distribution, or use of
the information contained herein is prohibited. If you have received
this communication in error, please destroy all copies of the message,
whether in electronic or hard copy format, as well as attachments, and
immediately contact the sender by replying to this e-mail or by phone.
Thank you.
I am looking for a feature which I hope NGINX supports, and that is
optimization of serving CSS files, specifically around minimizing and
resolving @import statements server side.
For instance, to better manage the hundreds of css files we have, we
started breaking them up and using the @import directive. Obviously this
slows things down quite a bit because the browser has to make lots of
additional requests.
Ideally, on production server it would cache the result and serve
that on all following requests.
Pretty trivial task for nginx-perl. Shouldn’t take long to implement if
you are
already familiar with embedded perl.
CJ> Ideally, on production server it would cache the result and serve
CJ> that on all following requests.
CJ> However, on development servers we would need to disable caching of
CJ> the files so that we could see our changes take effect in real time.
A better alternative may be to manage them just like any software
package. Write a Makefile so that >make< links the various src css
files into a single file, and >make install< installs that into the
served directory.
Casey J.
easyDITA a product of Jorsek LLC
“CaseyDJordan” on LinkedIn, Twitter & Facebook
(585) 348 7399
This message is intended only for the use of the Addressee(s) and may
contain information that is privileged, confidential, and/or exempt from
disclosure under applicable law. If you are not the intended recipient,
please be advised that any disclosure copying, distribution, or use of
the information contained herein is prohibited. If you have received
this communication in error, please destroy all copies of the message,
whether in electronic or hard copy format, as well as attachments, and
immediately contact the sender by replying to this e-mail or by phone.
Thank you.