PHPackages                             vrana/jush - 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. vrana/jush

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

vrana/jush
==========

JUSH - JavaScript Syntax Highlighter

v3.1.0(1w ago)282.7M↓20.1%79Apache-2.0PHP

Since Mar 2Pushed 2w ago4 watchersCompare

[ Source](https://github.com/vrana/jush)[ Packagist](https://packagist.org/packages/vrana/jush)[ Docs](https://jush.sourceforge.io/)[ RSS](/packages/vrana-jush/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependenciesVersions (10)Used By (9)

JUSH - JavaScript Syntax Highlighter
====================================

[](#jush---javascript-syntax-highlighter)

Highlights the full stack of PHP application starting with HTML, PHP, SQL and JavaScript code and ending with HTTP headers, `php.ini` settings or database variables.

- [Demo](demo.html)
- [SQL highlighter for various databases](sql.html)
- [Tests](tests.html)
- [Homepage](https://jush.sourceforge.io/)

Features
--------

[](#features)

- Highlights and links documentation in spaghetti code like nothing else: ``
- Supported languages: everything related to PHP: HTML5, JS, JSON, CSS 3, SQL including variables (multiple dialects), `php.ini` directives, HTTP and e-mail headers, Apache config. Anything could be embedded into each other, e.g. `header("Content-Type: text/html")` or `color: expression(parentNode.style.color)`.
- Allows using HTML tags in source code (could be used for pointing out important parts): `echo "This part is important."`. Produces overlapping HTML tags in this case though.
- Performance is a priority.
- `` [syntax highlight](textarea.html).

Installation instructions
-------------------------

[](#installation-instructions)

1. Copy [jush.css](jush.css) and [jush.js](jush.js) into your directory.
2. Add following snippet before the `` tag in HTML file:

    ```

    jush.style('jush.css');
    jush.highlight_tag('code');

    ```

    All `` tags will be highlighted. Language is determined by the class name beginning with "jush-" (e.g. ``). Default language is `htm`. It is also possible to use ``.
3. If you want to enable dark mode, call `jush.style('jush-dark.css')`. To enable it only based on user preferences, call `jush.style('jush-dark.css', '(prefers-color-scheme: dark)')`.

Alternatively call `jush.highlight(language, text)` to syntax highlight single text.

Command-line help reference
---------------------------

[](#command-line-help-reference)

It is also possible to use JUSH for opening the appropriate documentation in a browser:

```
Syntax: node jush-help.js filename line column [tabsize] [word]
Example: node jush-help.js demo.html 2 2

```

The example should open a browser with documentation of the `` tag which is at position 2:2 of [demo.html](demo.html).

Updating language references
----------------------------

[](#updating-language-references)

The `update/` directory holds scripts which sync a language module's list of keywords, functions and classes from an upstream reference file. For example, [update/php.php](update/php.php) rebuilds the class and function lists in `modules/jush-php.js` from a `php.api` file (from [scite-files](https://github.com/moltenform/scite-files/blob/main/files/files/api_files/php.api)):

```
php update/php.php path/to/php.api

```

[update/sql.php](update/sql.php) rebuilds the MySQL/MariaDB lists in `modules/jush-sql.js` from the MySQL online manual (the index pages are cached in the given directory) and a checkout of [mariadb-docs](https://github.com/mariadb-corporation/mariadb-docs):

```
php update/sql.php path/to/mysql-cache path/to/mariadb-docs

```

###  Health Score

64

—

FairBetter than 99% of packages

Maintenance97

Actively maintained with recent releases

Popularity51

Moderate usage in the ecosystem

Community26

Small or concentrated contributor base

Maturity69

Established project with proven stability

 Bus Factor1

Top contributor holds 95.7% 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

Every ~385 days

Recently: every ~24 days

Total

9

Last Release

12d ago

Major Versions

v2.2.2 → v3.0.02026-07-21

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/117453?v=4)[Jakub Vrána](/maintainers/vrana)[@vrana](https://github.com/vrana)

---

Top Contributors

[![vrana](https://avatars.githubusercontent.com/u/117453?v=4)](https://github.com/vrana "vrana (292 commits)")[![peterpp](https://avatars.githubusercontent.com/u/1448883?v=4)](https://github.com/peterpp "peterpp (11 commits)")[![brusch](https://avatars.githubusercontent.com/u/142037?v=4)](https://github.com/brusch "brusch (1 commits)")[![derStephan](https://avatars.githubusercontent.com/u/7764931?v=4)](https://github.com/derStephan "derStephan (1 commits)")

---

Tags

syntax-highlightingjavascriptSyntax highlighter

### Embed Badge

![Health badge](/badges/vrana-jush/health.svg)

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

###  Alternatives

[tightenco/ziggy

Use your Laravel named routes in JavaScript.

4.3k51.2M364](/packages/tightenco-ziggy)[matthiasmullie/minify

CSS &amp; JavaScript minifier, in PHP. Removes whitespace, strips comments, combines files (incl. @import statements and small assets in CSS files), and optimizes/shortens a few common programming patterns.

2.0k34.0M502](/packages/matthiasmullie-minify)[laracasts/utilities

Transform your PHP to JavaScript

2.2k10.6M67](/packages/laracasts-utilities)[tedivm/jshrink

Javascript Minifier built in PHP

76440.8M195](/packages/tedivm-jshrink)[symfony/ux-turbo

Hotwire Turbo integration for Symfony

3938.7M96](/packages/symfony-ux-turbo)[dkcwd/dkcwd-zf2-munee

Zend Framework 2 module leveraging 'munee' an asset optimisation library developed by Cody Lundquist. You can find munee at http://github.com/meenie/munee

102.1k](/packages/dkcwd-dkcwd-zf2-munee)

PHPackages © 2026

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