I have a react application hosted on Heroku and I made a static html landing page in a different project.
I'm tryiing to set it up so when I go to the url:
myreactapp.herokuapp.com the static html page will show up
While when I go to:
myreactapp.herokuapp.com/link/1
My working react application will load.
How do I approach this? Do I use the react router? The node backend router? Or is it an Heroku configuration issue?
Thanks.
Related
I have a local app with a Django backend and Vue3 frontend, and I have to deploy it to a Dreamhost Shared Host. I've already deployed the backend with Django and Passenger and it's working (the admin panel and its API is working), but now I need to add the frontend side to the server.
I've followed the instructions to deploy a Vue app, generating the dist folder with npm run build and then adding it to my public folder in the server, but nothing happens. I can't find any tutorial or anyone trying to build something similar, so any help to understand what I should have to do is welcomed.
I am new here and new to Laravel, sorry if I am posting in the wrong place or if I should ask it in another place. I have a Laravel application I want to deploy on Google Cloud Platform - App Engine. However I want a setup with a landing page and the laravel app in a different directory, so I can have something like mydomain.com poiting for my landing page and dashboard.mydomain.com poiting to my Laravel app. How is the best approach to make it:
1 - Two Laravel apps one for the landing page and one for the dashboard application in a subdirectory?
2 - A simple static html landing in the main directory and the laravel dashboard appication in a subdirectory?
3 - Two separeted google cloud platform projects, one for the landing page and the other for the dashboard app?
I have no idea how is the best and professional method of doing it here. I really appreciate some opinions here.
I am new to shopify, I want to create a public app which can communicate with store.
I have created a shopify partner account, an app and setup a Codeigniter project. Also added app url using ngrok.
Can anyone guide me with what should be the next step?
When you say public app I believe that you want to set a view or functionality available to your customers, and that will communicate with your store. Let's say your store is:
https://mystore.myshopify.com
Your App should consider an URL for backend and frontend. Probably the App that you have now is the backend and will be embedded in your Admin Dashboard after you have installed. By now, I'm assuming that you got it done.
Backend: https://4b67b991.ngrok.io/backend
Frontend: https://4b67b991.ngrok.io/frontend
The App you created should have the scope "Online Store" so that you can set up a Proxy App.
Once you set up a Proxy app, with let's say:
Sub path prefix: apps
Subpath: myapp
Proxy URL: https://4b67b991.ngrok.io/frontend
Now, when you go to: https://mystore.myshopify.com/apps/myapp, the proxy URL will be embedded in your store using the header and footer of your theme and in the middle area, you can create your custom functionality using the Shopify API.
Before your app can be embedded in the frontend (with header and footer), you should change the content type of your document. In Laravel I use the following code:
$response = Response::make($contents, 200);
$response->header('Content-Type', 'application/liquid');
Your question is quite general and I'm 100% sure about what you want to achieve, but I believe that it's a starting point.
My Laravel 5.6 app has a Vue.js frontend. The Vue.js app is in the resources directory. I have gone through several articles that use Prerender SPA plugins. These articles are for the stand alone vue.js app and have an index.html file. In Laravel's case we have index.php. How do I make my Laravel Vue.js App SEO freindly. At a minimum I would like to make the front/home page of the app SEO friendly.
I think, as an alternative solution, you can use https://prerender.io/ service (up to 250 pages Free for caching) to do the pre-rendering for your SPA application.
If you are going to implement https://prerender.io/ service, you would require to generate all the sitemap URL paths and upload them to this service via their npm plugin (prerender-spa-plugin) and configure your .htaccess file for search engine crawlers. So search engine crawlers will redirect to this pre-render service and picked your website, cached static web page for service engine indexing, and show that cached page as the search result.
For more info, you can refer below;
https://prerender.io/documentation
https://snipcart.com/blog/vue-js-seo-prerender-example
Cheers!
Definitely recommend checking out Nuxt.js! It is a production-ready framework built on top of VueJS. With Nuxt.js You can create 100% SEO-friendly app with SPA-like routing.
Check this awesome Toptal article about "Creating Server-side Rendered Vue.js Apps Using Nuxt.js"
I finished developing a Single Page Application using Vue Js in the front end to consume the APIs that I built with Laravel in the backend
I already deployed an old Laravel-only App in my shared hosting but now with all the new js files and node modules I have no idea what to do
I can't find any good tutorial or article, your help will be so much appreciated!
ps: I am using webpack to mix my SPA files