npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

eslint-plugin-tera

v0.1.0

Published

First-class ESLint language, lint rules, and formatting for Tera templates

Readme

eslint-plugin-tera

First-class ESLint language support, correctness rules, and opt-in formatting for Tera templates. It runs independently of Tera Tools, VS Code, and Zola.

Requirements

  • Node.js 20.19 or newer.
  • ESLint 9.39 or ESLint 10.
  • ESLint flat config (eslint.config.js, .mjs, or .cjs).

Install

pnpm add --save-dev eslint eslint-plugin-tera

For standalone .tera files:

// eslint.config.mjs
import tera from 'eslint-plugin-tera'

export default [
  ...tera.configs.recommended,
]
npx eslint "**/*.tera"

Formatting is deliberately opt-in:

export default [
  ...tera.configs['recommended-with-formatting'],
]

Run npx eslint --fix "**/*.tera" to apply it. The formatter changes only Tera regions; it never reformats surrounding HTML.

Zola HTML templates

The built-in presets match only **/*.tera. Opt known template directories into the Tera language instead of claiming every HTML file in a repository:

import tera from 'eslint-plugin-tera'

export default [
  ...tera.configs.recommended,
  {
    ...tera.configs.recommended[0],
    files: [
      'templates/**/*.html',
      'themes/*/templates/**/*.html',
    ],
  },
]

This analyzes Tera regions inside HTML, including regions embedded in <script> text, while leaving HTML and JavaScript validation to their own tools. Do not apply the Tera language to .vue, .jsx, or .tsx files.

Presets and rules

| Preset | Behavior | | --- | --- | | base | Registers tera/tera without rules. | | recommended | Enables correctness rules, never formatting. | | formatting | Enables only the fixable tera/format rule. | | recommended-with-formatting | Enables correctness and formatting rules. |

| Rule | Default | Fixable | Purpose | | --- | --- | --- | --- | | tera/syntax-error | recommended | No | Invalid, unclosed, or dialect-incompatible Tera syntax. | | tera/no-duplicate-arguments | recommended | No | Duplicate named arguments in calls. | | tera/component-parameters | recommended | No | File-local Tera 2 Component declaration parameters. | | tera/format | opt-in | Yes | Canonical formatting inside Tera regions. |

Component validation is currently file-local. Project-wide declaration resolution, completion, navigation, hover, and Zola-aware diagnostics remain the responsibility of Tera Tools until ESLint has an explicit project service.

Guides

Architecture

The package bundles the runtime-neutral parser, analyzer, and Tera-region formatter from @tera-tools/language-core. Consumers install only this plugin and ESLint; no language server or unpublished workspace dependency is needed. Both ESM import and CommonJS require entry points are provided.