Architecture
Bellow is the file structure of our frontend and backend, we accentually repeat the same structure for each product, within our app, however , it is important to only use the product files for custom development, whenever possible use existing widgets and model available within the shared folders, for a list of available widgets and models searsch our documentation or ask in the chat for what you are trying to acomplish.
If you notice your custome widgets are being utilized by other products, consider moving them into shared.
- Backend
- Frontend
Folder Structure
backend/
├── lib/
│ ├── dev/
│ │ ├── generate_token.dart
│ │ └── test_jwt.dart
│ ├── middleware/
│ │ ├── api_token_middleware.dart
│ │ └── firebase_middleware.dart
│ ├── actions.dart
│ ├── env.dart
│ ├── firebase_auth_helper.dart
│ ├── firebase_public_keys.dart
│ ├── routes.dart
│ └── server.dart
├── .env
├── .env.local
├── Dockerfile
├── pubspec.yaml
.
|-- lib
| |-- turtleneck
| | |-- foun //foundation
| | | |-- assets
| | | |-- typo
| | | |-- colors
| | | | |-- pallets
// seperate pallets & tokens by primary, secondary & tertiary
| | | | | |-- color_pallete.dart
| | | | | `-- primary.dart
| | | | `-- tokens
| | | | |-- design_tokens.dart
| | | | `-- primary.dart
| | | `-- themes
| | | `-- app_theme.dart
| | |-- atoms
| | |-- comp //components
| |-- features
| | |-- core
| | | |-- const
| | | |-- models
| | | |-- providers
| | | |-- services
| | | |-- utils
| | | |-- views
| | | |-- widgets
| | | `-- router.dart
| | |-- sample_feature
| | | |-- config
| | | |-- models
| | | |-- providers
| | | |-- utils
| | | |-- services
| | | |-- views
| | | |-- widgets
| | |-- advertising
| | |-- authentication
| | |-- categories
| | |-- channels
| | |-- comments
| | |-- content
| | |-- downloads
| | |-- feedback
| | |-- history
| | |-- home
| | |-- intro
| | |-- likes
| | |-- music
| | |-- notifications
| | |-- payments
| | |-- playlist
| | |-- podcast
| | |-- radio
| | |-- rent
| | |-- reporting
| | |-- search
| | |-- sections
| | |-- settings
| | |-- shorts
| | |-- splash
| | |-- subscription
| | |-- video
| | |-- video_creation
| | |-- wallet
| | |-- watch_later
| |-- web_js //why is this here?
| |-- firebase_options.dart
| `-- main.dart
|-- test
| `-- widget_test.dart
|-- README.md
|-- analysis_options.yaml
|-- devtools_options.yaml
|-- firebase.json
|-- flutter_launcher_icons.yaml
`-- pubspec.yaml