Skip to content

CaptainFact/captain-fact-frontend

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

1c7abc8 Β· Jan 15, 2025
Jan 8, 2023
Jan 15, 2025
Jan 8, 2023
Jan 17, 2024
Jan 17, 2024
Jan 8, 2023
Jan 15, 2025
Jan 15, 2025
Feb 7, 2024
Jan 15, 2025
Sep 1, 2020
Jan 8, 2023
Apr 2, 2019
Nov 1, 2017
Jan 15, 2025
Jan 15, 2025
Jan 8, 2024
Mar 26, 2024
Feb 27, 2018
Mar 28, 2021
Jan 15, 2025
Jan 15, 2025
Jan 15, 2025
Jan 15, 2025
Jan 15, 2025
Jan 15, 2025
Jan 17, 2024

Repository files navigation

Discord

AGPL3 GitHub release Release Status Coverage Status Translation status



Getting started

If you're already have the API running locally, a simple npm install && npm start should be enough. Otherwise follow the procedure below:

Front-end is started on http://localhost:3333

A default account should have been created for you with e-mail=[email protected] and password=password.

Conventions

File structure

app
β”œβ”€β”€ API => API libraries for both REST API and websockets
β”œβ”€β”€ assets => Assets imported from JS
β”œβ”€β”€ components => All react components
β”œβ”€β”€ i18n => Translations
β”œβ”€β”€ lib => Misc utilities
β”œβ”€β”€ state => All redux related
β”‚   β”œβ”€β”€ comments
β”‚   β”‚   β”œβ”€β”€ effects.js => Async actions creators, always return a promise
β”‚   β”‚   β”œβ”€β”€ record.js => The object representing a single comment
β”‚   β”‚   β”œβ”€β”€ reducer.js => Reducer + actions creators, always return an action object
β”‚   β”‚   └── selectors.js => Re-select selectors to select data in state
β”‚   └── ...
β”œβ”€β”€ static => Static assets, directly copied to the public directory
└── router.jsx => Application router and main entry point

Styling

Styling is based on Bulma and was initially customized with SASS. However we now include styled-components, styled-system and @rebass/grid. This has become the prefered way to build new components.

Icons

We bundle a custom font icon built with IcoMoon. You can find scripts and config for this in dev/ but the preferred (and easiest) way to add new icons today is to use https://styled-icons.js.org/.

Main Libraries / Frameworks

Linked projects

License

GNU AFFERO GENERAL PUBLIC LICENSE Version 3

Permissions of this strongest copyleft license are conditioned on making available complete source code of licensed works and modifications, which include larger works using a licensed work, under the same license. Copyright and license notices must be preserved. Contributors provide an express grant of patent rights. When a modified version is used to provide a service over a network, the complete source code of the modified version must be made available.

See LICENSE for more info.