{"id":27349523,"url":"https://github.com/mahdimashayekhi-ai/django-projects","last_synced_at":"2025-06-10T20:34:44.569Z","repository":{"id":176111226,"uuid":"617397797","full_name":"MahdiMashayekhi-AI/Django-Projects","owner":"MahdiMashayekhi-AI","description":"Django Projects Repository is a collection of open-source projects built with Django, showcasing best practices and use cases for web app development. It's a great resource for learning and inspiration.","archived":false,"fork":false,"pushed_at":"2023-06-19T15:54:42.000Z","size":19690,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-12T19:17:43.260Z","etag":null,"topics":["dajngo","project","python","source-code"],"latest_commit_sha":null,"homepage":"https://mahdimashayekhi.ir","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MahdiMashayekhi-AI.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-03-22T10:02:51.000Z","updated_at":"2025-03-30T12:23:16.000Z","dependencies_parsed_at":null,"dependency_job_id":"a0891980-ffd3-483e-b8de-41e0946d4391","html_url":"https://github.com/MahdiMashayekhi-AI/Django-Projects","commit_stats":null,"previous_names":["mahdimashayekhi-ai/django-projects"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MahdiMashayekhi-AI%2FDjango-Projects","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MahdiMashayekhi-AI%2FDjango-Projects/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MahdiMashayekhi-AI%2FDjango-Projects/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MahdiMashayekhi-AI%2FDjango-Projects/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MahdiMashayekhi-AI","download_url":"https://codeload.github.com/MahdiMashayekhi-AI/Django-Projects/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MahdiMashayekhi-AI%2FDjango-Projects/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259146400,"owners_count":22812222,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dajngo","project","python","source-code"],"created_at":"2025-04-12T19:17:42.352Z","updated_at":"2025-06-10T20:34:44.557Z","avatar_url":"https://github.com/MahdiMashayekhi-AI.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Django Projects 🐍🐌\n\n[![Build status](https://gitlab.com/thorgate-public/django-project-template/badges/master/pipeline.svg)](https://gitlab.com/thorgate-public/django-project-template/commits/master)\n\n[Django](https://www.djangoproject.com/) Projects Repository is a collection of open-source projects built with Django, showcasing best practices and use cases for web app development. It's a great resource for learning and inspiration.\n\nBest suited for medium-sized and bigger apps that use JavaScript and React for frontend or single page web applications.\n\n_(note that the primary repo is in [Gitlab](https://gitlab.com/thorgate-public/django-project-template), with mirror in [Github](https://github.com/thorgate/django-project-template))_\n\n\n## Features\n\n- Django-based backend\n\n    - [Django](https://www.djangoproject.com/)\n    - Separate settings for different environments (local/staging/production)\n    - Python 3.6 or later\n    - [SPA] Accessible from port `3000` for local development\n\n- Frontend app with JavaScript (ES2015), React and Sass\n\n    - Latest JavaScript features from [ES2015](https://babeljs.io/docs/learn-es2015/) and beyond, transpiled with\n      [Babel](https://babeljs.io/)\n    - [React](https://facebook.github.io/react/) for fast modular user interfaces\n    - [Sass](http://sass-lang.com/), [PostCSS](http://postcss.org/) and\n      [Autoprefixer](https://github.com/postcss/autoprefixer) for more convenient styling\n    - [Webpack](https://webpack.github.io/) is used to bundle and minify JavaScript and styles\n    - [SPA] [Razzle](https://razzlejs.org/) for preconfigured isomorphic application\n    - [SPA] Accessible from port `8000` for local development\n\n- Batteries\n\n    - Docker / Docker Compose integration\n    - Linting of Python, JavaScript and Sass code with [Prospector](http://prospector.landscape.io/),\n      [ESLint](http://eslint.org/) and [stylelint](https://stylelint.io/)\n    - Automated code-formatting using [black](https://black.readthedocs.io) and [prettier](https://prettier.io)\n    - [py.test](http://pytest.org/) and [coverage](https://coverage.readthedocs.io/) integration\n    - Deploy helpers, using [Ansible](https://www.ansible.com/)\n    - Media files are stored in a CDN like S3 or Google Cloud Storage\n    - Out-of-the-box configuration for nginx, gunicorn and logrotate\n    - Includes [PyCharm](https://www.jetbrains.com/pycharm/) project config\n\n\n## Usage\n\nTo use this template, first ensure that you have\n[Poetry](https://python-poetry.org/docs/) available.\n\nAfter that, you should:\n\n1. Install the requirements of the project template by running\n    ```\n    pip install -r requirments.txt\n    ```\n2. Activate the virtualenv created by pipenv:\n    ```\n    pipenv shell\n    ```\n3. Navigate to the directory where you'd like to create your project:\n    ```\n    cd /home/my-awesome-projects/\n    ```\n\n4. Create a new project by executing:\n    ```\n    cookiecutter dir/to/django-projects/\n    ```\n\n\nIt will ask you a few questions, e.g. project's name, python version and so on. **For a reference of all the configuration options** see [CookiecutterVariables.md](./CookiecutterVariables.md) file.\n\n\n\nTo create isomorphic single-page application set `frontend_style == spa`. Then separate node application will be created supported by [Razzle](https://razzlejs.org/)\n\nAfter generation completes, **you should deactivate virtual environment for cookiecutter**,\nsearch for any TODOs in the code and make appropriate changes where needed.\n\nSee README.md in the generated project for instructions on how to set up your development environment.\n\n\n## Different frontend styles\n\n### SPA\n\nIsomorphic Javascript single-page application rendered with node and backed by Django Rest Framework. Enabled with `frontend_style == spa`.\nDuring development and production separate node container is used to run and serve assets if needed.\nTranslations are done with [i18next](https://www.i18next.com/) and its companion library for React.\n\n### Webapp\n\nReact powered application rendered with Django templates. This is the default option. Enabled with `frontend_style == webapp`.\nDuring development separate container is used to build assets. In production, node built with multi-stage image.\nTranslations are done with Django JavaScriptCatalog.\n\n\n## Upgrading project template\n\nFirst ensure you have a python3 interpreter with `cookiecutter` installed.\n\nTo upgrade an existing project, change the current working directory to the root of the project you want to upgrade. i.e. `cd project-to-upgrade`. Ensure your have not checked out the `template` branch.\n\nThen run `python ~/path/to/django-project-template/upgrade-template.py`\n\nThis will make a commit to the branch `template` in your project with the updates to the project template. Then merge the `template` branch.\n\n## Applying codemods\n\nFirst activate Python 3 interpreter with required dependencies and ensure `docker` is installed and working.\n\nChange the current working directory to the root of the project you want to apply codemods for. i.e. `cd project-to-upgrade`.\n\nThen run `python ~/path/to/django-project-template/upgrade-template.py --apply-frontend-codemods`\n\nThis will build custom docker image to update old frontend versions.\n\n## Docker images\n\nThe template uses our own images for CI runs. One for the template itself and a second one\nfor generated projects. Both images are alpine based and contain python3, pip and some support\npackages. The images are published to [repository container registry](https://gitlab.com/thorgate-public/django-project-template/container_registry) and also to [docker hub](https://hub.docker.com/u/thorgate).\n\nThe images are built in CI (from default branches only) and also updated every day via schedules.\n\n**Project CI Image**\n\n- [Dockerfile-ci](./utils/Dockerfile-ci)\n- Image in repository registry: `registry.gitlab.com/thorgate-public/django-project-template/ci`\n- Image in docker hub: `thorgate/django-template-ci`\n  - [see online](https://hub.docker.com/r/thorgate/django-template-ci)\n\n**Template CI Image:**\n\n- [Dockerfile-base-ci](./utils/Dockerfile-base-ci)\n- Image in repository registry: `registry.gitlab.com/thorgate-public/django-project-template/base-ci`\n- Image in docker hub: `thorgate/django-template-base-ci`\n  - [see online](https://hub.docker.com/r/thorgate/django-template-base-ci)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahdimashayekhi-ai%2Fdjango-projects","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmahdimashayekhi-ai%2Fdjango-projects","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahdimashayekhi-ai%2Fdjango-projects/lists"}