{"id":24991,"library":"bemhtml-compat","title":"BEMHTML Compat","description":"A transpiler that converts legacy BEMHTML source code (pre-2013 syntax) into modern JavaScript-compatible code for BEM frameworks. Current stable version is 0.1.2, with no active development since 2014. It is a specialized tool for migrating BEMHTML templates from the old declarative format to the new functional style using `match()` calls. Its key differentiator is handling the syntax shift in BEM libraries, but it has been superseded by direct development on BEMHTML and is no longer maintained.","status":"abandoned","version":"0.1.2","language":"javascript","source_language":"en","source_url":null,"tags":["javascript"],"install":[{"cmd":"npm install bemhtml-compat","lang":"bash","label":"npm"},{"cmd":"yarn add bemhtml-compat","lang":"bash","label":"yarn"},{"cmd":"pnpm add bemhtml-compat","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"ESM import is preferred; CommonJS require also works but is outdated.","wrong":"const bemcompat = require('bemhtml-compat')","symbol":"default","correct":"import bemcompat from 'bemhtml-compat'"},{"note":"transpile is a named export, not default.","wrong":"import transpile from 'bemhtml-compat'","symbol":"transpile","correct":"import { transpile } from 'bemhtml-compat'"}],"quickstart":{"code":"import bemcompat from 'bemhtml-compat';\nconst result = bemcompat.transpile('block b1, tag: \"a\"');\nconsole.log(result); // match(this.block === 'b1', this._mode === 'tag')('a');","lang":"javascript","description":"Transpiles an old-style BEMHTML block declaration to modern JavaScript."},"warnings":[{"fix":"Use the built-in BEMHTML transpilation features in the 'bem' package or write templates directly in modern BEMHTML syntax.","message":"Package is no longer maintained and has been abandoned since 2014. No compatibility with modern Node.js versions beyond v0.10.","severity":"gotcha","affected_versions":">=0.1.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run 'npm install bemhtml-compat' (version 0.1.2). If that fails, the package may have been unpublished.","cause":"Package not installed or removed from npm? It still exists but is not maintained.","error":"Error: Cannot find module 'bemhtml-compat'"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}