Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bedita/api-template
BE4 API project template
https://github.com/bedita/api-template
Last synced: about 1 month ago
JSON representation
BE4 API project template
- Host: GitHub
- URL: https://github.com/bedita/api-template
- Owner: bedita
- Created: 2021-08-03T13:54:01.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2024-09-30T12:30:56.000Z (3 months ago)
- Last Synced: 2024-11-08T17:16:20.492Z (2 months ago)
- Language: PHP
- Size: 165 KB
- Stars: 2
- Watchers: 5
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# BEdita API template
[![Github Actions](https://github.com/bedita/api-template/workflows/php/badge.svg)](https://github.com/bedita/api-template/actions?query=workflow%3Aphp)
[![codecov](https://codecov.io/gh/bedita/api-template/branch/master/graph/badge.svg)](https://codecov.io/gh/bedita/api-template)This is the skeleton app to build BEdita5 API projects.
## Requirements
1. PHP >= 8.2
1. Download latest [Composer](https://getcomposer.org/doc/00-intro.md) or update via `composer self-update`.## Installation
Simply run
```bash
composer create-project bedita/api-template
```In case you want to use a custom app dir name (e.g. `myapp/`):
```bash
composer create-project bedita/api-template myapp
```You can now either use your machine's webserver to view the default home page, or start
up the built-in webserver with:```bash
bin/cake server
```Then visit `http://localhost:8765` to see the welcome page.
## Configuration
Review and edit accordingly every configuration item in `config/app_local.php`.
Make sure at least `Datasources` points to the desired DB instance.## Namespace
You need to manually change the default `MyApp` namespace in order to use a custom one (recommended before any application logic is introduced).
Files referencing `MyApp` are:
* `composer.json`
* `bin/cake.php`
* `config/app.php` or override in `config/app_local.php`
* `src/Console/installer.php`
* `src/Shell/ConsoleShell.php`
* `Application.php` (and `test/TestCase/ApplicationTest.php`)
* `webroot/index.php`Make sure to launch `composer dump-autoload` after this manual change in order to update autoloader data