PHP framework for web applications and APIs. Configured with Bootstrap, but could just as easily support others.
- WSL (Windows Subsystem for Linux) is a great development environment for PHP, there some notes about installing wsl here
mkdir newapp
cd newapp
The application relies on the composer autoload features, this (very) basic composer.json file tells the autloader where to look for this application and installs bravedave/dvc
composer.json
{
"require": {
"bravedave/dvc": "*"
},
"autoload": {
"psr-4": {
"": "src/app/"
}
}
}
note: this is the same location used in the composer.json file
composer u
mkdir -p src/app
file src/app/application.php
<?php
class application extends bravedave\dvc\application {
static public function startDir() {
return dirname(__DIR__);
}
}
this creates a documentroot and copies in a fallback file
cp -R vendor/bravedave/dvc/tests/www src
php -S localhost:8080 src/www/_mvp.php
available at http://localhost:8080
there is a tutorial here