βΉοΈOverview
Course Structure
A course is just a directory with a particular structure. The goal of this document is to detail this structure.
All the TypeScript courses crafted by the community must be located in this mono-repository.
π Start by taking a look at the README.
Directory structure
The simplified directory structure can be described as follow:
arenas/
βββ your-arena-name/
βββ src/
β βββ course-config.json
β βββ challenges/
β β βββ my-challenge1/
β β βββ my-challenge2/
β βββ fights/
β βββ my-fight-1/
the
arenas
directory contains all the Arenas (aka courses) made by the communitythe
you-arena-name
represents one arena (aka one course)the
challenges
directory must contain every challenges that are available in this arenathe
fights
directory contains the list of fights. A fight is a group of challenges for your Arena.the
course-config.json
file contains general course information, such as the order of the fights
In depth
Fights Directory Structure
The fights
directory is itself composed of subfolders. Each subfolder is named with the unique identifier of the fight.
In each subfolder, there is a config.json
file that defines the configuration of a fight.
This configuration contains general information such as:
the description of the fight
the order of the challenges
the materials url (videos or slides) : optional
and more...
Challenges Directory Structure
The challenges folder contains a subfolder for each challenge.
Each subfolder is named with the unique identifier of the challenge. Each challenge folder has the following structure:
a
config.json
file that is used to store data related to the challenge.a
challenge.md
file that contains the instructions in french and its English counterpartchallenge-en.md
, in markdown format.It contains the instructions presented on the left side of the challenge page.
Note: if you are an English speaker, do not bother with french translation, we will do it for you
A
julius
subfolder that contains the Julius configuration for this challenge as well as the tests to be executed.
Julius Subfolder of a Challenge Folder
The julius subfolder includes a config.json
file that indicates which runner to use and which options.
In 99.9999% of cases, there is nothing to change on your side.
There is a test
folder where all the jest test files, written in TS, should be placed.
The .test.ts
extension is mandatory for tests.
When Julius tests the code, it copies the test
folder and moves one level up the function written by the user.
That's why in the example test, we import from ..
.
If you want to create utility functions to facilitate testing, add them to the test
folder WITHOUT the .test.ts
extension. Then import them into your tests.
One level above, the reference implementation, is often written to test the tests.
The user's repo content will replace all this "one level above" when Julius checks.
Last updated