Improve SEO by pre-rendering all HTML pages
* Change all internal links to use URLs ending in `/` * Add the prerender script which uses PhantomJS to pre-render the HTML for all possible pages in the system * Change the build process to incorporate the pre-rendered files * Update the sitemap script to generate the new URLs
This commit is contained in:
+2
-5
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env coffee
|
||||
#
|
||||
# Crafting Guide - server
|
||||
# Crafting Guide - serve-build
|
||||
#
|
||||
# Copyright (c) 2014-2015 by Redwood Labs
|
||||
# All rights reserved.
|
||||
@@ -45,10 +45,7 @@ app.get '*', (request, response)->
|
||||
console.log ">>> #{request.path}"
|
||||
|
||||
response.set 'Content-Type', contentType
|
||||
|
||||
sendFile = -> response.sendFile request.path, root:ROOT
|
||||
|
||||
setTimeout sendFile, 100 # change the zero to post files after a short delay
|
||||
response.sendFile request.path, root:ROOT
|
||||
|
||||
server = app.listen 8000, ->
|
||||
console.log "listening at: #{server.address().address}:#{server.address().port}"
|
||||
|
||||
Reference in New Issue
Block a user