iProland React Gatsby & Next Product Landing Page Template
Welcome To iProland
Thanks for purchasing this theme, your support is truly appreciated!
This document covers the installation and use of this theme and often reveals answers to common
problems and issues - read this document thoroughly if you are experiencing any difficulties. If
you have any questions that are beyond the scope of this document, feel free to email at
devscorn@gmail.com
Thank you so much!
Template Features
- Available in Nextjs & Gatsbyjs version
- Based on styled components
- Individual theming options
- Individual style loding for making page load superfast
- Reusable components for highly customization
- Clean & Simple Design
- Nextjs & Gatsbyjs for SSR(server side rendaring) support
- No CSS or SCSS file
- Fully Responsive Design
- Cross Browser Compatible with IE11+, Firefox, Safari, Opera, Chrome
Every image or media size should under 1MB
What Inside of iProland & How to configure
How to configure & Install Packages
When you get iProland.zip file form Themeforest first needt to unzip the file you will find two folder,
one folder contain iProland-Nextjs version and other file contain iProland-Gatsby version.
iProland run in Next.js server
- First go-to in next-landing folder
- run
yarn install
on next-landing - run
yarn dev
on next-landing
Then , please go to address localhost:7070 on your browser and You will find default landing
page.
Similarly
localhost:7070/ for Watch Landing Page
localhost:7070/mobile for mobile Landing Page
localhost:7070/cycle for cycle Landing Page
localhost:7070/blog-grid for Blog-Grid Page
localhost:7070/blog-list for Blog-List Page
localhost:7070/blog-single for Blog-Single Page
localhost:7070/about for about Page
localhost:7070/ratting for ratting Page
localhost:7070/team for team Page
localhost:7070/product-single for product-single Page
iProland run in Gatsby.js server
- First go-to in gatsby-landing folder
- run
yarn install
on gatsby-landing folder - run
yarn dev
on gatsby-landing folder
Then , please go to address localhost:8000 on your browser and You will find default landing
page.
Similarly
localhost:8000/ for Watch Landing Page
localhost:8000/mobile for mobile Landing Page
localhost:8000/cycle for cycle Landing Page
localhost:8000/blog-grid for Blog-Grid Page
localhost:8000/blog-list for Blog-List Page
localhost:8000/blog-single for Blog-Single Page
localhost:8000/about for about Page
localhost:8000/ratting for ratting Page
localhost:8000/team for team Page
localhost:8000/product-single for product-single Page
next-landing folder Structure
After entering next-landing folder, You will find some other folders.
- pages
- src
In pages folder
In this folder , you will find the pages folder of next js and next configuration files. If you want to change something in next js folder , change here .
pages
As we have used next.js , we have a script to your package.json like this:
{ "scripts": { "dev": "next -p 7070", "start": "next start", "now-build": "next build && next export -o dist", "netlify-build": "next build && next export", "firebase-dev": "npm run dev:client & npm run dev:server", "firebase-dev:client": "next src/client", "firebase-dev:server": "babel src/server --out-dir dist/server --source-maps --watch", "firebase-build:client": "next build src/client", "firebase-build:server": "babel src/server --out-dir dist/server --source-maps", "firebase-build": "npm run build:client && npm run build:server", "firebase-preserve": "npm run build", "firebase-serve": "cross-env NODE_ENV=production firebase serve --only functions,hosting", "firebase-predeploy": "rimraf dist/ && npm run build", "firebase-deploy": "cross-env NODE_ENV=production firebase deploy --only functions,hosting" } }
After that, the file-system is the main API. Every .js file becomes a route that gets
automatically processed and rendered.
Please have a look at this link https://nextjs.org/docs/ for a quick look. You will
understand the basic things so quickly.
As we have Three Product landing pages, three blog pages, four others pages named index, mobile, cycle, blog-grid,
blog-list, blog-single, about, team, ratting, product-single so we have ten js files named:
index.js for Watch landing Page.
mobile.js for Mobile landing Page.
cycle.js for cycle landing Page.
blog-grid.js for Blog Grid Page.
blog-list.js for Blog List Page.
blog-single.js for Blog-Single Page .
about.js for About Page .
ratting.js for Ratting Page .
team.js for Team Page .
product-single.js for Single-product Page .
In src folder
After entering to next-landing/src folder, You will find:
- assets
- components
- reusecore
- sections
- theme
Now, we will discuss about each and every folders and their tasks .
assets
In assets folder, you will find the data, images folder. In data folder, you will find all of data uses in this template. You will also find the image folder, where all of the images are kept on the basis of the specific page.
components
Here all the Components we use in iProland.
reusecore
reusecore folder is most importantly use, you will find some basic components like Layout,
Button, Counter, Navigation etc.
We have written these components to make the developer's life easy. Here in details:
Accordion -> By this you can make any Accordion with your own style
Alert -> By this you can make any Alert with your own style
Button -> By this you can make any Button with your own style
Box -> By this you can align any area of block with your own style
Counter -> By this you can make any Counter with your own style
Layout -> Here in Layout all grid system are included
PageHeader -> By this you can make BreadCrumb with your own style
SectionTitle -> By this you can make any SectionTitle with your own style in
template
SlickSlider -> By this you can make any slider with your own style in
template
By using these basic components, you can write custom components according to your need.
section
After entering to sections folder, You will find:
- blog
- common
- cycle
- essentialPages
- mobile
- watch
blog
all blog layouts here, like:
- blog-grid
- blog-list
- blog-single
- blog-sidebar
common
all common section are here, like:
- contact
- footer
- navigation
- news
- pageHeader
- testimonial
cycle
cycle folder contain all cycle landing sections
mobile
mobile folder contain all mobile landing sections
watch
watch folder contain all watch landing sections
essentialPages
all essentialPages section are here, like:
- about
- product
- ratting
- team
theme
In theme folder, you will find all of themeing uses in this template.
Here all themeing elements, we use in iProland.If you need color related customization, you can menage it from here.
gatsby-landing folder structure
After entering gatsby-landing folder, You will find some other folders.
- src
In src folder
After entering to gatsby-landing/src folder, You will find:
- assets
- components
- pages
- reusecore
- sections
- theme
Now, we will discuss about each and every folders and their tasks .
assets
In assets folder, you will find the data, images . In data folder, you will find all of data uses in this template. You will also find the image folder, where all of the images are kept on the basis of the specific page.
components
Here all the Components we use for gatsby in iProland.
in pages folder
In this folder , you will find the pages folder of gatsby and gatsby configuration files. If you want to change something in gatsby folder , change here .
pages
As we have used gatsby , we have a script to your package.json like this:
"scripts": { "build": "gatsby build", "develop": "gatsby develop", "dev": "npm run develop", "start": "npm run develop", "serve": "gatsby serve", "clean": "gatsby clean", "now-build": "yarn run build", "format": "prettier --write \"**/*.{js,jsx,json,md}\"" }
After that, the file-system is the main API. Every .js file becomes a route that gets
automatically processed and rendered.
Please have a look at this link https://www.gatsbyjs.com/ for a quick look. You will
understand the basic things so quickly.
As we have Three Product landing pages, three blog pages, four others pages named index, mobile, cycle, blog-grid,
blog-list, blog-single, about, team, ratting, product-single so we have ten js files named:
index.js for Watch landing Page.
mobile.js for Mobile landing Page.
cycle.js for cycle landing Page.
blog-grid.js for Blog Grid Page.
blog-list.js for Blog List Page.
blog-single.js for Blog-Single Page .
about.js for About Page .
ratting.js for Ratting Page .
team.js for Team Page .
product-single.js for Single-product Page .
Here all the Components we use in iProland.
reusecore
reusecore folder is most importantly use, you will find some basic components like Layout,
Button, Counter, Navigation etc.
We have written these components to make the developer's life easy. Here in details:
Accordion -> By this you can make any Accordion with your own style
Alert -> By this you can make any Alert with your own style
Button -> By this you can make any Button with your own style
Box -> By this you can align any area of block with your own style
Counter -> By this you can make any Counter with your own style
Layout -> Here in Layout all grid system are included
PageHeader -> By this you can make BreadCrumb with your own style
SectionTitle -> By this you can make any SectionTitle with your own style in
template
SlickSlider -> By this you can make any slider with your own style in
template
By using these basic components, you can write custom components according to your need.
section
After entering to sections folder, You will find:
- blog
- common
- cycle
- essentialPages
- mobile
- watch
blog
all blog layouts here, like:
- blog-grid
- blog-list
- blog-single
- blog-sidebar
common
all common section are here, like:
- contact
- footer
- navigation
- news
- pageHeader
- testimonial
cycle
cycle folder contain all cycle landing sections
mobile
mobile folder contain all mobile landing sections
watch
watch folder contain all watch landing sections
essentialPages
all essentialPages section are here, like:
- about
- product
- ratting
- team
theme
In theme folder, you will find all of themeing uses in this template.
Here all themeing elements, we use in iProland.If you need color related customization, you can menage it from here.
iProland deployment process
Gatsby Cloud Deployment for Gatsbay
- Upload your project into github/gitlab or bit bucket. Make this project private or public whatever you want.
- Go to gatsby cloud
- Choose i already have a site and get start
- Fillout the all available options
- Select your project repository from github/gitlab
- You may skip Integrations
- Then press create site
Vercel Deployment for Nextjs
-
npm i -g vercel
-
vercel --prod
Install the Vercel CLI
Firebase Deployment for Nextjs
- Init firebasebase and create firbase project into project folder
-
Before we go next delete
public/index.html
-
Open .babelrc file in editor and replace this code to
module-resolver alias
"alias": { "assets": "./src/client/assets", "components": "./src/client/components", "sections": "./src/client/sections", "reusecore": "./src/client/reusecore" }
-
Open
firebase.json then replace with this code{ "hosting": { "public": "public", "rewrites": [ { "source": "**/**", "function": "nextjs-server" } ] }, "functions": { "source": ".", "ignore": [ ".firebase/**", ".firebaserc", "firebase.json", "**/node_modules/**", "**/public/**" ] } }
-
install
yarn add firebase-admin firebase-functions
yarn add @babel/core @babel/cli @babel/preset-env cross-env rimraf -dev
-
Open package.json and this code
"main": "dist/server/index.js", "engines": { "node": "10" }
if you face engine related issues then run
yarn config set ignore-engines true
- Create two client and server folder into src/
- select > pages, > assets, > components, > reusecore, > sections and move into client folder
- add .babelrc, index.js into src/server/
-
open .babelrc in editor and add this code
{ "presets": [ [ "@babel/preset-env", { "targets": { "node": "10.15.3" } } ] ] }
-
open index.js in editor and add this code
import * as admin from "firebase-admin"; import * as functions from "firebase-functions"; import next from "next"; admin.initializeApp(); const dev = process.env.NODE_ENV !== "production"; const app = next({ dev, // the absolute directory from the package.json file that initialises this module // IE: the absolute path from the root of the Cloud Function conf: { distDir: "dist/client" }, }); const handle = app.getRequestHandler(); const server = functions.https.onRequest((request, response) => { // log the page.js file or resource being requested console.log("File: " + request.originalUrl); return app.prepare().then(() => handle(request, response)); }); const nextjs = { server, };
-
Finally run
firebase-build
firebase-preserve
firebase-serve
yarn firebase-predeploy
yarn firebase-deploy
Stack We Used in iProland
- Yarn Workspace.
- React Js.
- Next Js.
- Gatsby Js.
- Styled Components.