-
Notifications
You must be signed in to change notification settings - Fork 180
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
is there any way that allow prender middleware return pages of specific routes ? #172
Comments
Could you give an example? You can use the whitelist and blacklist as seen on the readme to only allow specific routes to be sent to Prerender. |
@thoop yeah! i'used spliting code in my app! it's mean the Js file that represent for a route just downloaded to excute if only the user vistit that route! example: Home.js file will be downloaded if user visit my-app/home, the problem is come from here, i saw the middleware just return the js file of the master route. |
I'm not sure what you mean. If a crawler accesses the root "/" URL then Prerender would render the root "/" URL. If a crawler accessed the "/home" URL then Prerender would render the "/home" URL. Are you seeing something else happening? |
/home and not thing responded! i think because my serve just serve the route "/" and the return the index.html at this route! so if crawler visit the route /home, nothing will be responed |
As long as the prerender-node middleware is running before you serve back your index.html page, then everything should work properly. Do you have an upstream server like nginx/apache that is modifying the URL to just the "/" route before sending it to your node server? |
oh! i did'nt use a webserver yet! i just set-up a pre-render server and an express server with the middleware |
That should be fine then. Can you post your express configuration with any private information removed? |
No description provided.
The text was updated successfully, but these errors were encountered: