weixin_33736832 2016-08-08 20:43 采纳率: 0%
浏览 47

PrerenderIO流星用法

I am attempting to use the prerenderIO Package in my meteor web app and am not sure if I am using it correctly. I followed to instructions on the package and have added the package to my webapp, then set my prerenderIO token in my settings.json file like so...

settings.json

{
"PrerenderIO": {
    "token": "XXXXXXXXXXXXXX"

},
"public": {

},
"private": {



}
}

Is there another step that I am missing? Do I need to call a method somewhere? Any insight would be hugely appreciated and thank you in advanced.

  • 写回答

1条回答 默认 最新

  • weixin_33749242 2016-08-09 17:07
    关注

    Follow these steps to get prerender.io setup and tested with your Meteor app locally:

    1) Install the dfischer:prerenderio package:

    meteor add dfischer:prerenderio
    

    2) Add the Prerender settings to your settings.json file:

    {
      "PrerenderIO": {
        "token": "yourtoken"
      }
    }
    

    3) Start your app locally (making sure to reference your settings.json):

    meteor --settings=settings.json
    

    4) Install and start a local Prerender server for testing (make sure you change the default port of 3000 since it will conflict with Meteor's default port):

    git clone https://github.com/prerender/prerender.git
    cd prerender
    npm install
    export PORT=3100 
    node server.js
    

    5) Access your local Meteor app through your local Prerender instance:

    http://localhost:3100/http://localhost:3000
    

    6) In your browser, view source; you'll see the rendered HTML for your application instead of referenced javascript files/calls.

    评论

报告相同问题?

悬赏问题

  • ¥15 基于卷积神经网络的声纹识别
  • ¥15 Python中的request,如何使用ssr节点,通过代理requests网页。本人在泰国,需要用大陆ip才能玩网页游戏,合法合规。
  • ¥100 为什么这个恒流源电路不能恒流?
  • ¥15 有偿求跨组件数据流路径图
  • ¥15 写一个方法checkPerson,入参实体类Person,出参布尔值
  • ¥15 我想咨询一下路面纹理三维点云数据处理的一些问题,上传的坐标文件里是怎么对无序点进行编号的,以及xy坐标在处理的时候是进行整体模型分片处理的吗
  • ¥15 CSAPPattacklab
  • ¥15 一直显示正在等待HID—ISP
  • ¥15 Python turtle 画图
  • ¥15 stm32开发clion时遇到的编译问题