Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/scify/dianoia-marketplace
A Marketplace app to create content for people with dementia.
https://github.com/scify/dianoia-marketplace
assistive-technology clean-code eslint hacktoberfest laravel laravel-application laravel-framework laravel-mix mvc php pint solid solid-principles vue vuejs
Last synced: about 23 hours ago
JSON representation
A Marketplace app to create content for people with dementia.
- Host: GitHub
- URL: https://github.com/scify/dianoia-marketplace
- Owner: scify
- License: apache-2.0
- Created: 2021-10-18T17:24:49.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2024-05-02T11:39:50.000Z (6 months ago)
- Last Synced: 2024-05-02T23:53:14.027Z (6 months ago)
- Topics: assistive-technology, clean-code, eslint, hacktoberfest, laravel, laravel-application, laravel-framework, laravel-mix, mvc, php, pint, solid, solid-principles, vue, vuejs
- Language: PHP
- Homepage: https://dianoia.scify.org/
- Size: 32.9 MB
- Stars: 3
- Watchers: 6
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Dianoia Marketplace Web Application
[![GitHub Issues](https://img.shields.io/github/issues/scify/Dianoia-Marketplace)](https://img.shields.io/github/issues/scify/Dianoia-Marketplace)
[![GitHub Stars](https://img.shields.io/github/stars/scify/Dianoia-Marketplace)](https://img.shields.io/github/stars/scify/Dianoia-Marketplace)
[![GitHub forks](https://img.shields.io/github/forks/scify/Dianoia-Marketplace)](https://img.shields.io/github/forks/scify/Dianoia-Marketplace)
[![JavaScript Style Guide: Good Parts](https://img.shields.io/badge/code%20style-goodparts-brightgreen.svg?style=flat)](https://github.com/dwyl/goodparts "JavaScript The Good Parts")
[![contributions welcome](https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat)](https://github.com/dwyl/esta/issues)
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://GitHub.com/Naereen/StrapDown.js/graphs/commit-activity)
[![Ask Me Anything !](https://img.shields.io/badge/Ask%20me-anything-1abc9c.svg)](https://GitHub.com/scify)Laravel 10 Web Application for Creating content for the Dianoia mobile app
[Project URL](https://dianoia.scify.org/)
# Installation Instructions:
## Pre-initialization steps
After cloning the project, create an .env file (should be a copy of .env.example),
containing the information about your database name and credentials:```bash
cp .env.example .env
```Take a look at the `.env` file that was created. You may need to update the `DB_*` variables, in order to set up the DB connection.
Also, make sure that the `APP_URL` is set to the correct domain and port that you will be using.
## First time install (setup database and install dependencies)
0. Make sure php 8.0 (or newer) is installed.
1. After cloning the project, create an .env file (should be a copy of .env.example),
containing the information about your database name and credentials.
Then run ```php artisan migrate``` to create the DB schema and
```php artisan db:seed``` in order to insert the starter data to the DB2. Install laravel/back-end dependencies
```bash
composer installcomposer dump-autoload
```3. Front-end dependencies
It is very easy to install multiple versions of NodeJS and npm, by using [Node Version Manager (nvm)](https://github.com/creationix/nvm).
If you are using [`nvm`](https://github.com/nvm-sh/nvm), run this command in order to sync to the correct NodeJS version for the project:
```bash
nvm use
```Then, install and compile the front-end dependencies:
```bash
npm installnpm run dev #(use prod if in production)
```4. Create the symbolic link for user-uploaded files.
```bash
php artisan storage:link
```in order to link the `/public/storage` folder with the `/storage/app/public` directory
## SEO - Generate Sitemap
This application uses [Spatie - Laravel Sitemap](https://github.com/spatie/laravel-sitemap) plugin, in order to create
the `public/sitemap.xml` file (which is excluded from git), that will be crawled by the search engines.
In order to run the generator for the current application installation, run the embedded Laravel command:```bash
php artisan sitemap:generate
```
## PHP code style - Laravel PintThis application uses [Laravel Pint](https://laravel.com/docs/9.x/pint) in order to perform code-style.
In order to run the styler, run :
```bash
./vendor/bin/pint --test -v # the --test will not do any changes, it will just output the changes needed./vendor/bin/pint -v # this command will actually perform the code style changes
```## Apache configuration example:
```
% sudo touch /etc/apache2/sites-available/dianoiamarketplace.conf
% sudo nano /etc/apache2/sites-available/dianoiamarketplace.conf
ServerName dev.dianoiamarketplace
ServerAlias dev.dianoiamarketplace
DocumentRoot "/home/path/to/project/public"
Require all granted
AllowOverride all
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined```
Make the symbolic link:
```
% cd /etc/apache2/sites-enabled && sudo ln -s ../sites-available/dianoiamarketplace.conf
```
Enable mod_rewrite, mod_ssl and restart apache:
```
% sudo a2enmod rewrite && sudo a2enmod ssl && sudo service apache2 restart
```Fix permissions for storage directory:
```bash
sudo chown -R ${USER}:www-data storagechmod 775 storage
cd storage/
find . -type f -exec chmod 664 {} \;
find . -type d -exec chmod 775 {} \;
```Or run the `set-file-permissions.sh` script (needs sudo):
```bash
sudo ./set-file-permissions.sh www-data {{app_user}} .
```Change hosts file so dev.dianoiamarketplace points to localhost
```$xslt
sudo nano /etc/hosts127.0.0.1 dev.dianoiamarketplace
```## How to debug
- Install and configure Xdebug on your machine
- At Chrome install [Xdebug helper](https://chrome.google.com/webstore/detail/xdebug-helper/eadndfjplgieldjbigjakmdgkmoaaaoc?utm_source=chrome-app-launcher-info-dialog)
- At PhpStorm/IntelliJ click the "Start listening for PHP debug connections"