Shishir 2020 - NIT Meghalaya's Cultural Festival
- Clone the "working" branch. If on master branch already, run:
git pull origin working
in the terminal - Switch to working branch by runnning:
git checkout working
- Make changes and push into this branch only.
- run
yarn install
if freshly cloned.
- Run
yarn dev
- Go to
localhost:3000
in your browser
- Run
yarn build
to build the project - After building, run:
yarn start
- Go to the specified url (usually localhost:3000)
- If there are no errors, then the branch is deployable.
- Before merging the 'working' branch to the 'master' branch, the /lib/absoluteUrl.js file must be changed
Uncomment:
const origin = "https://shishir2020.herokuapp.com"
andconst url = origin + path;
Comment:const url = "http://localhost:3000" + path;
- Switch to the master branch. run:
git checkout master
- Merge the working branch to master:
git merge working
- Commit and push the changes. Wait for a few minutes while HEROKU builds the project, then visit the website to view changes.
- Create JSON objects for any information needed to be stored
(like events.json)
and store them in the "public" folder. - FETCH these objects using "getInitialProps"
(like in index.js)
- getInitialProps can only be called from components in the "PAGES" folder
- DO NOT use "import React from 'react'". it is redundant in the
Nextjs framework.
- For the sake of
uniformity and standard
, all components will have the file extension (*.js)] - Each NEW page (in the pages folder) will be in a folder. Each of these new folders will have an "index.js" page which marks the entry point for the particular route.
Contains the pages that we wish to display. Creating subfolders in the 'pages' folder will change the url of the page being fetched.
Store all static assets (like text files, json files, images etc) here.
The UI elements that we will put in our pages
contains the theme that we will use
Upper level application component that runs when NEXTJS is ran.
Follow the color palette:
$primary-color: #eb2f64;
$primary-color-light: #FF3366;
$primary-color-dark: #BA265D;
$color-background-dark:#1b262c;
$color-grey-light-1: #faf9f9;
$color-grey-light-2: #f4f2f2;
$color-grey-light-3: #f0eeee;
$color-grey-light-4: #ccc;
$color-grey-dark-1: #333;
$color-grey-dark-2: #777;
$color-grey-dark-3: #999;
$text-color:#333;
$shadow-dark: 0 2rem 6rem rgba(0,0,0,.3);
$shadow-light: 0 2rem 5rem rgba(0,0,0,.06);
.u-margin-bottom-large
.u-margin-bottom-medium
.u-margin-bottom-small
.u-margin-top-large
.u-margin-top-medium
.u-margin-top-small
.container
.paragraph
.u-center-text