Return Home

Nano Core

A consistent and flexible base for core application needs.

Not a Microframework

While microframeworks offer most of what is needed to handle basic application requests, the inKWell nano core occupies an even smaller niche. Instead, the core focuses on giving you the tools to integrate packages of your choice in a normalized environment. It provides you a basic directory structure, application initalization, modular configuration tools, error handling, and dependency injection. In short, rather than telling you what tools to use, it gives you the foundation to use and re-use those tools effectively.

Nano Core Features

Modular Configuration

Using the nano core you can break your configuration into pieces that make sense to you and easily query specific values from within your bootstrapping logic. Whether you need a single value from a single file or a series of common data structures across multiple files, it is easy to retrieve, iterate, and provide defaults during your application initialization.

$this->fetch('my/config', 'some.nested.value', 'default');

Creating per-environment configurations or extend and overload via multiple tagged configuration trees is as simple as copying a config to a new directory, modifying it, and adjusting an environment variable.

IW_ENVIRONMENT = "aws,prod"

Pluggable Bootstrapping

Enable service configuration and setup by simply dropping files into place or create opus packages to copy pluggable actions during composer installation.

cp vendor/acme/router/plugin/inkwell.php boot/routing.php

Adjust the preferred order of initialization by defining dependencies which should be run prior (if they exist). Combined with composer and opus to make plugin integration 100% automatic.

return Affinity\Action::create(['routing'], function($app, $broker) { ... });

Dependency Injection

Change concrete interface providers using the same modular configuration which enables your first and third-party components to be easily integrated.

'@providers' => ['mapping' => ['Acme\SomeInterface' => 'Concrete\Provider']]

Recursively resolve construction dependencies when creating new instances using the robust Auryn dependency injector.

$instance = $broker->make('Acme\SomeInterface');