Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some questions #11

Open
yubozhao opened this issue Apr 28, 2014 · 6 comments
Open

Some questions #11

yubozhao opened this issue Apr 28, 2014 · 6 comments

Comments

@yubozhao
Copy link

Hi @ayal

First, good job on this package. I am just having some questions on this topic. I think you might have the answer I seek.

  1. Could you tell me the difference or advantage add the header on the server side rather than client side? I am really new in this topic. Would love you to fill out some blanks in my head.
  2. Do you happen to know in what order for connectHandler(WebApp) to handle incoming request? What if Iron router handle it before this package?(I am assuming the order matters for connectHandler)

Thank you for the package. Love to hear back from you.

@mitar
Copy link

mitar commented May 1, 2014

Could you tell me the difference or advantage add the header on the server side rather than client side? I am really new in this topic. Would love you to fill out some blanks in my head.

You have to do it on the server side because this is what spiders fetch. They don't run JavaScript.

@yubozhao
Copy link
Author

yubozhao commented May 2, 2014

Hi @mitar Thank you so much for your answer. I am trying to understand this thoroughly, got couple more follow up questions. :)

So lets assumed a case that I have iron router installed and spiderable installed as well. I have set meta data with IR's beforeAction hook. When I do curl -i APPADDRESS?escaped_fragment=, it returns correct header. And this is not what google spider will get?

@yubozhao
Copy link
Author

yubozhao commented May 2, 2014

Also @mitar From Headly's code, it add metadata into headers, if useragent is one of the 2(facebook and twitter). How would it helps for Googlebot?

Oops Mybad, It said in description it works for facebook's og metadata.

@mitar
Copy link

mitar commented May 2, 2014

If you want support for Google, use spiderable.

@mitar
Copy link

mitar commented May 2, 2014

And yes, interaction between spiderable, headly, and iron-router is probably not well defined.

@yubozhao
Copy link
Author

yubozhao commented May 2, 2014

Just rereading the blog post from Matt about spiderable. He said "When a spider requests an HTML snapshot of a page, the Meteor server runs the client half of the application and returns the full HTML generated by the client code."

That is where I got really confused about adding meta data on the server side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants