Hellooooo most of the things here is written by create-svelte
. Thx svelte for saving me the time to write a README.md file
So first, you'll want to install dependencies with npm install
. After that, we can start a development server:
npm run dev
# or start the server and open the app in a new browser tab
npm run dev -- --open
To create a production version of your app:
npm run build
You can preview the production build with npm run preview
.
To deploy your app, you may need to install an adapter for your target environment.
In +layout.svelte that correspond to the navbar on homepage, there's a class called AppPages to represent the different pages. To create an instance, pass in the Page Title and path to folder as arguments. ie "new AppPages("Invoice Upload", "/invoice_upload").
After creating the instance, push that instance into the list called appPagesList. The existing code is designed to push items in appPagesList to generate the links in navbar.
FE will try and keep this updated everytime we make a change. Ideally, it should show how the pages/components are currently implemented
Page
Check you are starting from the correct branch (frontend) by doing 'git branch'
git checkout frontend
to navigate to correct branchfrontend
branch, do git pull
git fetch
followed by git merge
does the same thing.Before you start your own work, do ensure to do things from your own working branch.
git branch <child_branch> <parent_branch>
david
from frontend
, I would do git branch david frontend
git checkout david
Stage file using git add <file1> <file2>
. Don't use git add .
unless you only have edited/added files to be commited.
Commit with meaning messages using git commit -m "message"
At this stage, all commits should have only been your own working local branch. ie david
branch only exisit on your local repo. The next step is merging any conflicts from origin/frontend
, ie the frontend branch on remote or github.
git checkout frontend
.git pull
to bring in any changes on origin/frontend onto your local frontend branch.checkout david
.git rebase frontend
to bring changes on local frontend branch to local working branch. Once you are sure that there are no more conflicts, we will bring our changes to frontend branch:
git checkout frontend
git rebase david