From b5f3066d3fb96a6016b478d7a6227d3b711adf8b Mon Sep 17 00:00:00 2001 From: Dave Mc Nicoll Date: Tue, 17 Oct 2023 17:58:00 +0000 Subject: [PATCH] - WIP on Picea's asset autoload --- composer.json | 16 ++++++++++++++-- meta/config.php | 9 +++++++++ meta/definitions.php | 18 ++++++++++++++++++ 3 files changed, 41 insertions(+), 2 deletions(-) create mode 100644 meta/config.php create mode 100644 meta/definitions.php diff --git a/composer.json b/composer.json index 58d0987..ca0b879 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "assets-package/font-awesome5", "description": "Font awesome 5 PRO", - "type": "library", + "type": "asset", "license": "MIT", "authors": [ { @@ -10,5 +10,17 @@ } ], "require": {}, - "autoload": {} + "autoload": {}, + "extra" : { + "lean" : { + "autoload": { + "definitions" : [ + "meta/definitions.php" + ], + "config": [ + "meta/config.php" + ] + } + } + } } diff --git a/meta/config.php b/meta/config.php new file mode 100644 index 0000000..60c2175 --- /dev/null +++ b/meta/config.php @@ -0,0 +1,9 @@ + [ + 'autoload' => [ + 'assets.fontawesome5' + ] + ], +]; diff --git a/meta/definitions.php b/meta/definitions.php new file mode 100644 index 0000000..6781093 --- /dev/null +++ b/meta/definitions.php @@ -0,0 +1,18 @@ + [ + 'picea' => [ + 'asset' => [ + 'source' => [ + [ + 'path' => implode(DIRECTORY_SEPARATOR, [ $path, "asset", '' ]), + 'order' => 10 + ] + ], + ] + ], + ], +];