Skip to content
A simple implementation of the "Godfather" approach
JavaScript Other
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
bin/scripts/provision
config
lib
.gitignore
LICENSE
README.md
Vagrantfile

README.md

perl-prerender

A simple implementation of the "Godfather" approach

Setup

to powerup the solution simply run

$ vagrant up && vagrant ssh

Server-side`

Start the web server

$ cd lib/server
$ perl server.pl
# >> Dancer2 v0.163000 server 1718 listening on http://0.0.0.0:3000

Now you should be able to access http://localhost:9001

Start the PhantomJS server

cd lib/server
perl prerender.pl
# >> Dancer2 v0.163000 server 1722 listening on http://0.0.0.0:3001

Client-side app

The client-side app is build with ReactJS, to build or watch your changes simply run

$ cd lib/client
$ webpack --watch

Grabbing the prerendered content

$ curl -A "googlebot" http://localhost:9001
You can’t perform that action at this time.