Mod pagespeed library/API?

29 views
Skip to first unread message

Luci

unread,
Sep 17, 2013, 7:06:24 AM9/17/13
to mod-pagesp...@googlegroups.com
Hi,

I am investigating a different approach to optimizing website content - server-side (ie. pre-webserver) optimization.

Is there documented access to a mod_pagespeed library, API or service to use its different optimization filters as on-demand function calls?

For example, if my code dynamically produces images, or deals with user-uploaded images, I would like to be able to save or output a ready-optimized version of an image. Or minifying/combining JS/CSS (I know there are other tools for this), minifying HTML at the end of a buffered flush, etc. Can I access pagespeed functions as a post-processing layer in my application?

Thanks.

Luci


Joshua Marantz

unread,
Sep 23, 2013, 4:23:38 PM9/23/13
to mod-pagespeed-discuss
Yes you can.  mod_pagespeed has an API: http://modpagespeed.com/psol/annotated.html.

The main drawback of pre-optimizing a site is that it's harder to do some of the things mod_pagespeed does:
  • serve content optimized for the user-agent, e.g. webp for Chrome/Opera, higher compression ratio for phones
  • inlining small resources into HTML
  • combining
And of course you'll have to integrate the build step into your content generation flow.  What is the main reason you are thinking of trying this approach?

-Josh


--
You received this message because you are subscribed to the Google Groups "mod-pagespeed-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mod-pagespeed-di...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/mod-pagespeed-discuss/3aeedeb7-a97e-481f-9a73-a7254e813b0c%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages