HabitRPG/habitrpg — pull request #2827 by paglias (2014-02-12 14:34:06+00:00)
Title: Optimizations

**WIP**

In this pull request I'm going to add optimization-related commits regarding mainly the build system (grunt, caching). This goes toghether with https://github.com/HabitRPG/habitrpg-shared/pull/149

Done:

- Only one css for page load, using grunt-contrib-cssmin to rewrite urls to images and other resources
- grunt run:dev simplified
- cache bootstrap icon fonts, spritesmith using grunt-hashres
- use icons from spritesmith for coins in notifications (removed old icons from habitrpg-shared, they don't seems to be used anywhere else)
- remove `gemoji` from bower because we're loading emojis from habitrpg-shared (cc @snicker )
- cache emojis: they are a lot of files and we can't rename them or copy them to build so I set caching directly from /public for them. It would cause problems only if an image changes (not if a new one is added) but I don't this is going to happen often (probably never).

This should cut down a lot on requests for static files especially emojis.

To do:

- We can cache the images used on static pages but I'm not really sure about that, if it would be useful.

If I missed something let me know.

cc @lefnire