# Critical path CSS with sage gulpfile

**URL:** https://discourse.roots.io/t/critical-path-css-with-sage-gulpfile/4618
**Category:** sage
**Tags:** gulp
**Created:** 2015-08-29T13:12:07Z
**Posts:** 5

## Post 1 by @Paalt — 2015-08-29T13:12:07Z

Hi. Google pagespeed insight recommends inlining the most critical css and load the full css document async to get a faster render time.

[Critical](https://github.com/addyosmani/critical) does exactly this with gulp.  
My question is this: Does anyone know how to implement “Critical” into the sage gulpfile without breaking it. My experience with gulp is limited, so any input is very welcome.

---

## Post 2 by @austin — 2015-08-29T15:55:56Z

The use-case for Critical is mostly single page apps and sites that have static templates. [https://github.com/pocketjoso/penthouse](https://github.com/pocketjoso/penthouse) is more appropriate for dynamic sites.

They have a usage example here: [https://github.com/pocketjoso/penthouse/tree/53984aa423a30581142b6cfc19c3d694ba0dc49e#usage-2](https://github.com/pocketjoso/penthouse/tree/53984aa423a30581142b6cfc19c3d694ba0dc49e#usage-2)

---

## Post 3 by @Paalt — 2015-08-29T16:13:06Z

Ok, so what I wonder then, is do I just do the npm install in my sage directory and paste the usage code into my gulpfile.js(and then alter it)? Will that work?

---

## Post 4 by @kalenjohnson — 2015-08-29T22:32:28Z

You can give it a try

---

## Post 5 by @dandin84 — 2017-04-26T14:28:21Z

hi, did you succeed?
