How to improve SEO for servers without a server?

I want to improve SEO (i.e. correctly indexing my pages in search engines) in a serverless architecture when my site is hosted on AWS S3.

Since I use the JavaScript approach for routing (something like angular, but simpler) and getting dynamic content to populate the meta tags, I find everything that can be quite annoying for a scraper without JavaScript support, like Facebook.

I have default meta tags that are already inserted, and of course they are loaded just fine, but I need updated ones.

I know that most people use pre-rendering on the server or through something like Prerender.io, but I really wanted to find an alternative that makes sense on a serverless approach.

I thought it turned out, since the Open Graph meta tags allow you to specify the URL of pointers where you can have HTML code with meta tags, if necessary. So I was thinking about using the Lambda function to generate an HTML response with the correct meta tags on a GET request. The problem is that the Facebook scraper does not support JavaScript, how can I send dynamic content on a GET request?

+4
source share
2 answers

S3, . Lambda , JavaScript. Prerender.io S3.

:

  • -.
  • PhanthomJS .
  • S3, *.

* : example.com/about/us us.html .

, JavaScript . , JavaScript, (Angular?) JS (, , ..) , SPA. , SPA .

Pros

  • .
  • . CloudFront .

  • 1000 (, 1000 , ), 1000 .
  • , .
  • *.

* , , , , SPA .


, S3. , S3. :

53 = > CloudFront = > API Gateway = > Lambda

:
- API CloudFront.
- "HTTPS Only" " " (CloudFront).
- - -.

Lambda HTML-.

:

  • Lambda , .

:

  • -.
+3

CloudFront S3, , prerender . Lambda @Edge - , . , .

01 2016 : Lambda @Edge -

, Hacker News, , AWS!

(...)

:

,    , Facebook   Twitter, .    , ,    Cloudfront.    Google/Facebook/Twitter ..,    .

beans , . , , .

(dec/2016), AWS, .

+4

Source: https://habr.com/ru/post/1661386/


All Articles