PHPackages                             kappa/assets-publisher - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. kappa/assets-publisher

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

kappa/assets-publisher
======================

Basic macros for better works with src and href attribute

0458PHP

Since Mar 1Pushed 11y ago1 watchersCompare

[ Source](https://github.com/Kappa-org/AssetsPublisher)[ Packagist](https://packagist.org/packages/kappa/assets-publisher)[ RSS](/packages/kappa-assets-publisher/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Kappa\\AssetsPublisher
======================

[](#kappaassetspublisher)

Basic macros for better works with src and href attribute

Requirements
------------

[](#requirements)

- PHP 5.4 or higher
- [nette/latte](https://github.com/nette/latte)
- [nette/di](https://github.com/nette/di)
- [nette/utils](https://github.com/nette/utils)

Installation:
-------------

[](#installation)

The best way to install Kappa\\AssetsPublisher is using Composer

```
$ composer require kappa/assets-publisher:@dev
```

And register macro `Kappa\AssetsPublisher\Macros\SourceMacro`. For example

```
nette:
	latte:
		macros:
			- Kappa\AssetsPublisher\Macros\SourceMacro
```

Configuration
-------------

[](#configuration)

```
documentRoot: %wwwDir%
assetsDir: assets
```

- `documentRoot` - You can set document root for all assets. Default value is %wwwDir% form parameters
- `assetsDir` - you can set name of assets dir. Default value is `assets`.

For example

```
documentRoo: /super/web/www
assetsDir: public/assets
```

Real path to assets will be `/super/web/www/public/assets` and all assets in template will have path `/public/assets`because `/super/web/www/` is document root and will be ignored.

Usages
------

[](#usages)

Now in template you can link files placed outside of public directory

```
 {* this create  *}
 {* this create  *}
```

**Note:** Macro automatically decide when to use `src` or `href` attribute. For more information please see [attributes section](http://www.w3.org/html/wg/drafts/html/master/index.html#web+-scheme-prefix) or this [implementation](https://github.com/Kappa-org/AssetsPublisher/blob/master/src/Macros/SourceMacro.php#L54-L55)

###  Health Score

22

—

LowBetter than 23% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/0c0840abca14f130b93d02cfa8412e99dc0645ca3f7e57cf75cfcb487efe33aa?d=identicon)[Budry](/maintainers/Budry)

---

Top Contributors

[![Budry](https://avatars.githubusercontent.com/u/990676?v=4)](https://github.com/Budry "Budry (30 commits)")

### Embed Badge

![Health badge](/badges/kappa-assets-publisher/health.svg)

```
[![Health](https://phpackages.com/badges/kappa-assets-publisher/health.svg)](https://phpackages.com/packages/kappa-assets-publisher)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
