Skip to content
Snippets Groups Projects
Commit 06b84740 authored by Josef Olsson's avatar Josef Olsson
Browse files

Fixed spelling using spellchecker

parent b51336bc
No related branches found
No related tags found
1 merge request!159Resolve "Documentation"
......@@ -2,7 +2,7 @@ Development
===========
In this section we give all the instructions necessary to continue the development of this project.
We also give some recommentations for how to go about it.
We also give some recommendations for how to go about it.
.. toctree::
:maxdepth: 2
......
......@@ -5,13 +5,13 @@ It is not that surprising, then, that we recommend you use it.
## Extensions
When you first open the repository in Visual Studio Code it will ask you to install all recommended extesions, which you should do.
When you first open the repository in Visual Studio Code it will ask you to install all recommended extensions, which you should do.
We used a few extensions to help with the development of this project.
The Python and Pylance extensions help with linting Python code, auto imports, syntax highliting and much more.
The Python and Pylance extensions help with linting Python code, auto imports, syntax highlighting and much more.
Prettier is an extension used to format JavsScript and TypeScript.
ESLint is used to lint JavsScript and TypeScript code.
Prettier is an extension used to format JavaScript and TypeScript.
ESLint is used to lint JavaScript and TypeScript code.
Live Share is an extension thats used to code together at the same time, much like a Google Docs document.
But there was a few issues with the Python extension that made Live Share hard to work with.
......@@ -33,14 +33,14 @@ The `Populate database` task will populate the database with a few competitions,
The `Test server` task will run the server tests located in the `server/tests/` folder.
The `Open server coverage` task can only be run after running the server tests and will open the coverage report generated by those tests in a webbrowser.
The `Open server coverage` task can only be run after running the server tests and will open the coverage report generated by those tests in a web browser.
The `Unit tests` task will run the unit tests for the client.
The `Run e2e tests` task will run the end-to-end tests.
The `Open client coverage` task can only be run after running the client tests (`Unit tests` task) and will open the coverage report generated by those tests in a webbrowser.
The `Open client coverage` task can only be run after running the client tests (`Unit tests` task) and will open the coverage report generated by those tests in a web browser.
The `Generate documentation` task will generate the project documentation, i.e. this document, in the `docs/build/html/` folder.
The `Open documentation` task can only be run after generating the documentation and will open it in a webbrowser.
The `Open documentation` task can only be run after generating the documentation and will open it in a web browser.
......@@ -16,7 +16,7 @@ sphinx-quickstart
You will be asked a few questions about how to configure Sphinx.
Just press enter on all, which will use the default.
You can enter the correct projet name and/or author if you want, but it's not necessary, no one but you will see it anyway.
You can enter the correct project name and/or author if you want, but it's not necessary, no one but you will see it anyway.
Then will need to modify a few files.
First add the following code snippet after the first block of comments, above the "project information" comment, in the file `./server/docs/conf.py`:
......
......@@ -18,4 +18,4 @@ npm install
You should now be ready to start the client.
Try it by running `npm run start`.
A webpage should open where you can see the [login page](../user_manual/login.md).
A web page should open where you can see the [login page](../user_manual/login.md).
# Server overview
The server has two main responsibilites.
The server has two main responsibilities.
The first is to handle API calls from the client to store, update and delete information, such as competitions or users.
It also needs to make sure that only authorized people can access these.
The other is to sync slides, timer and answers between clients in an active competition.
......@@ -12,7 +12,7 @@ An API call is a way the client can communicates with the server.
When a request is received the server begins by authorizing it (making sure the person sending the request is allowed to access the route).
After that it makes sure that it got all information in the request it needed.
The server will then do the thing the client requested.
And finally it will need to generate repsonse, usually in the form of an object from the database.
And finally it will need to generate response, usually in the form of an object from the database.
All of these steps are described in more detail below.
### Routes
......@@ -35,7 +35,7 @@ If the route is not decorated everyone is allowed to access it, the only routes
We use JSON Web Tokens (JWT) for authentication, both for API and socket events.
A JWT is created on the server when a user logs in or connects to competition.
We store some information in the JWT, which can be seen in the file `server/app/apis/auth.py`.
The JWT is also encrycpted using the secret key defined in `server/configmodule.py`.
The JWT is also encrypted using the secret key defined in `server/configmodule.py`.
(OBS: Change this key before running the server in production).
The client can read the contents of the JWT but cannot modify them because it doesn't have access to the secret key.
This is why the server can simply read the contents of the JWT to be sure that the client is who it says it is.
......@@ -44,7 +44,7 @@ This is why the server can simply read the contents of the JWT to be sure that t
After the request is authorized the server will need to parse contents of the request.
The parsing is done with [reqparse](https://flask-restx.readthedocs.io/en/latest/parsing.html) from RestX (this module is deprecated and should be replaced).
Each API call expects different parameters in different places and this is specificied in each of the files in `app/apis/` folder, together with the route.
Each API call expects different parameters in different places and this is specified in each of the files in `app/apis/` folder, together with the route.
### Handling request
......
......@@ -26,7 +26,7 @@ You will also be able to search for and filter users by their region or role.
## Competitions
The competitions tab will allow you to see all competitions, their name, region and year.
You will also be able to create a new competition by clicking the "Ny tävling" button or edit exisiting ones by clicking on their name.
You will also be able to create a new competition by clicking the "Ny tävling" button or edit existing ones by clicking on their name.
By click on the three dots "..." you will be able to start, show the codes for, copy or delete that competition.
![Competition manager](../_static/competitions.png)
......
......@@ -4,7 +4,7 @@ The login page will let you either login as a user or join a competition with a
## User
The first page you will be presented with when acessing the site is the login page.
The first page you will be presented with when accessing the site is the login page.
From here you can login with your account by typing your email and password in their respective fields and pressing the "Logga in" button.
![Login page](../_static/login.png)
......
......@@ -16,7 +16,7 @@ All the views have different purposes and therefore looks a little bit different
There are two ways to start a competition.
The first way is to navigate to the competition manager, press the three dots "..." and press "Starta".
You will then enter the operator view.
From there you will be able to go bewteen slides with the "<" and ">" buttons or start the timer, both will be synced between all clients connected to that competition.
From there you will be able to go between slides with the "<" and ">" buttons or start the timer, both will be synced between all clients connected to that competition.
You will also be able to view the scores for the teams and view all codes to the competition.
![Operator view](../_static/operator.jpg)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment