Skip to content

Single Page Application SEO 单页面应用搜索引擎优化

License

Notifications You must be signed in to change notification settings

jerryshell/spa-seo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Single Page Application SEO

Initialization

npm i

Test

npm run test

Start

pm2 start server.js

Nginx

location / {
    proxy_set_header  Host            $host:$proxy_port;
    proxy_set_header  X-Real-IP       $remote_addr;
    proxy_set_header  X-Forwarded-For $proxy_add_x_forwarded_for;
    try_files $uri $uri/ /index.html;
    # SSR for Search Engine Spider
    if ($http_user_agent ~* "Baiduspider|twitterbot|facebookexternalhit|rogerbot|linkedinbot|embedly|quora link preview|showyoubot|outbrain|pinterest|slackbot|vkShare|W3C_Validator|bingbot|Sosospider|Sogou Pic Spider|Googlebot|360Spider") {
        proxy_pass  http://127.0.0.1:8686;
    }
}

LICENSE

GPLv3

About

Single Page Application SEO 单页面应用搜索引擎优化

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published