PHPackages                             hypejunction/mustache - 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. hypejunction/mustache

ActiveElgg-plugin

hypejunction/mustache
=====================

Mustache templating in Elgg

1.0.0(10y ago)046GPL-2.0JavaScript

Since Oct 2Pushed 10y ago1 watchersCompare

[ Source](https://github.com/hypeJunction/mustache)[ Packagist](https://packagist.org/packages/hypejunction/mustache)[ Docs](http://hypejunction.com)[ RSS](/packages/hypejunction-mustache/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (3)Versions (3)Used By (0)

Mustache templating for Elgg
============================

[](#mustache-templating-for-elgg)

[![Elgg 2.0](https://camo.githubusercontent.com/981b94044a74b931be93e2825c7151896de9c8a53ccb960daf01b8fe0d800774/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f456c67672d322e302e782d6f72616e67652e7376673f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/981b94044a74b931be93e2825c7151896de9c8a53ccb960daf01b8fe0d800774/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f456c67672d322e302e782d6f72616e67652e7376673f7374796c653d666c61742d737175617265)

Features
--------

[](#features)

- Templates can be rendered both client and server side
- Compatible with Elgg's view system
- AMD-friendly

Usage
-----

[](#usage)

1. Create a new template as an Elgg view

```
// /my_plugin/views/default/path/to/template.html

	Hello, {{name}}

```

You can also use PHP views, e.g. `template.html.php`. This allows you to call other views and do stuff with PHP. If you use this approach, be sure to register the template views in simplecache, so that they are accessible with AMD.

```
// /start.php
elgg_register_simplecache_view('path/to/template.html.php');
```

```
// /my_plugin/views/default/path/to/template.html.php

	Hello, {{name}}

```

2. Render server-side

```
	echo mustache()->render(elgg_view('mustache/template.html'), array(
		'name' => elgg_get_logged_in_user_entity()->name,
	));
```

3. Render client-side

```
define(function(require) {

	var elgg = require('elgg');
	var mustache = require('mustache');
	var template = require('text!mustache/template.html');

	var view = mustache.render(template, {
		name: elgg.get_logged_in_user_entity().name
	});

	$('body').html(view);

});
```

Docs
----

[](#docs)

- mustache.js
- PHP Mustache

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity64

Established project with proven stability

 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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

3872d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/5071b1cd852e094b3f564962a625e04c227adc73af30c5b46b243ab8f20154a7?d=identicon)[hypeJunction](/maintainers/hypeJunction)

---

Top Contributors

[![hypeJunction](https://avatars.githubusercontent.com/u/1202761?v=4)](https://github.com/hypeJunction "hypeJunction (1 commits)")

---

Tags

pluginelggmustachetemplates

### Embed Badge

![Health badge](/badges/hypejunction-mustache/health.svg)

```
[![Health](https://phpackages.com/badges/hypejunction-mustache/health.svg)](https://phpackages.com/packages/hypejunction-mustache)
```

###  Alternatives

[coldtrick/group_tools

Combines different group additions into one plugin

305.1k](/packages/coldtrick-group-tools)[coldtrick/profile_manager

Improved management of user and group profile fields

293.7k1](/packages/coldtrick-profile-manager)[coldtrick/widget_manager

Manage your widgets

214.3k](/packages/coldtrick-widget-manager)[coldtrick/thewire_tools

Extend the functionality of The Wire

133.2k](/packages/coldtrick-thewire-tools)[coldtrick/translation_editor

Provide an easy way to edit translations

113.4k1](/packages/coldtrick-translation-editor)

PHPackages © 2026

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