Show your ❤️ - give us a ⭐
Help us grow this project to be the best it can be!
VueFront is a VueJS powered CMS agnostic SPA & PWA frontend for your old-fashioned Blog and E-commerce site.
OpenCart - Open-source eCommerce platform built with MVC pattern.
CMS Connect App - adds the connection between the OpenCart CMS and VueFront Web App via a GraphQL API.
This repo stores the codebase for the CMS Connect App for OpenCart. Because of OpenCart's versioning, the branches are structured as follows
Repo Branch | OpenCart Versions |
---|---|
master | 2.x-3.x |
1.5x | 1.5.x |
Since OpenCart does not have a built-in Blog, we use the Free Blog Module by Dreamvention for version 2.x-3.x
Php version required >= 5.5, <= 7.2 (this limitation will be removed in the future)
- Download the compiled Extensions from the latest releases.
- Upload via OpenCart Admin -> Extension Installer
- Go to Extensions -> Modules -> VueFront and click install
- Click edit to view copy the CMS Connect URL
You will need the CMS Connect URL to complete the VueFront Web App installation
The official compiled version of the CMS Connect APP includes other supporting extensions such as d_opencart_patch and d_twig_manager.
You can download the source code from the master branch directly and upload via ftp to your root folder. When activating the module, you should have the following extensions preinstalled: d_opencart_patch, d_twig_manager, d_twig (only for 2.x)
You can also install the d_blog_module to add blog features to VueFront.
If you have shopunity module installed, you can use that for a super quick installation:
- go to OpenCart admin -> shopunity -> marketplace tab
- search for VueFront
- Click install.
You can also install the d_blog_module via Shopunity as well.
- Install the VueFront CMS Connect App from this repo.
- Log in or register an account with VueFront.com
- Build your first Web App
- Activate the new Frontend Web App (only avalible for Apache servers)
For Nginx you need to add this code to your
nginx.config
file right after theindex
directive
location ~ ^((?!image|.php|admin|catalog|\/img\/.*\/|wp-json|wp-admin|wp-content|checkout|rest|static|order|themes\/|modules\/|js\/|\/vuefront\/).)*$ {
try_files /vuefront/$uri /vuefront/$uri "/vuefront${uri}index.html" /vuefront$uri.html /vuefront/200.html;
}
- Install the VueFront CMS Connect App from this repo.
- Log in or register an account with VueFront.com
- Copy the CMS Connect URL
- Via Ftp create a new folder
vuefront
in the root of your OpenCart site on your hosting. - Via command line build your VueFront Web App (read more)
yarn create vuefront-app
# When promote, provide the CMS Connect URL, which you coppied at step 3.
yarn generate
- Copy all files from folder
dist
to the newly createdvuefront
folder - modify you
.htaccess
file by adding afterRewriteBase
rule the following rules:
# VueFront scripts, styles and images
RewriteCond %{REQUEST_URI} .*(_nuxt)
RewriteCond %{REQUEST_URI} !.*/vuefront/_nuxt
RewriteRule ^([^?]*) vuefront/$1
# VueFront sw.js
RewriteCond %{REQUEST_URI} .*(sw.js)
RewriteCond %{REQUEST_URI} !.*/vuefront/sw.js
RewriteRule ^([^?]*) vuefront/$1
# VueFront favicon.ico
RewriteCond %{REQUEST_URI} .*(favicon.ico)
RewriteCond %{REQUEST_URI} !.*/vuefront/favicon.ico
RewriteRule ^([^?]*) vuefront/$1
# VueFront pages
# VueFront home page
RewriteCond %{REQUEST_URI} !.*(image|.php|admin|catalog|\/img\/.*\/|wp-json|wp-admin|wp-content|checkout|rest|static|order|themes\/|modules\/|js\/|\/vuefront\/)
RewriteCond %{QUERY_STRING} !.*(rest_route)
RewriteCond %{DOCUMENT_ROOT}".$document_path."vuefront/index.html -f
RewriteRule ^$ vuefront/index.html [L]
RewriteCond %{REQUEST_URI} !.*(image|.php|admin|catalog|\/img\/.*\/|wp-json|wp-admin|wp-content|checkout|rest|static|order|themes\/|modules\/|js\/|\/vuefront\/)
RewriteCond %{QUERY_STRING} !.*(rest_route)
RewriteCond %{DOCUMENT_ROOT}".$document_path."vuefront/index.html !-f
RewriteRule ^$ vuefront/200.html [L]
# VueFront page if exists html file
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !.*(image|.php|admin|catalog|\/img\/.*\/|wp-json|wp-admin|wp-content|checkout|rest|static|order|themes\/|modules\/|js\/|\/vuefront\/)
RewriteCond %{QUERY_STRING} !.*(rest_route)
RewriteCond %{DOCUMENT_ROOT}".$document_path."vuefront/$1.html -f
RewriteRule ^([^?]*) vuefront/$1.html [L,QSA]
# VueFront page if not exists html file
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !.*(image|.php|admin|catalog|\/img\/.*\/|wp-json|wp-admin|wp-content|checkout|rest|static|order|themes\/|modules\/|js\/|\/vuefront\/)
RewriteCond %{QUERY_STRING} !.*(rest_route)
RewriteCond %{DOCUMENT_ROOT}".$document_path."vuefront/$1.html !-f
RewriteRule ^([^?]*) vuefront/200.html [L,QSA]
For Nginx you need to add this code to your nginx.config file right after the index rule
location ~ ^((?!image|.php|admin|catalog|\/img\/.*\/|wp-json|wp-admin|wp-content|checkout|rest|static|order|themes\/|modules\/|js\/|\/vuefront\/).)*$ {
try_files /vuefront/$uri /vuefront/$uri "/vuefront${uri}index.html" /vuefront$uri.html /vuefront/200.html;
}
For support please contact us at Discord
For submitting an issue, please create one in the issues tab. Remember to provide a detailed explanation of your case and a way to reproduce it.
Enjoy!