neuron-explorer
Qwen3.5‑4B 전용 조향형 뉴런 탐색기, 모든 MLP 뉴런을 밀어 결과를 보관·탐색
markz는 작은 마크다운 언어와 이를 읽는 단일 패키지이며, 고정 방언과 소스 매핑 트리, HTML 출력만 제공한다
markz is a small Markdown language and the one package that reads it. It has one fixed dialect, a compact tree that maps every node back to the source, HTML output, and no options. A project makes its
개발 도구TypeScript · CSSGitHub @amitkaps온라인운영자 미확인
써 보셨어요? 한 번만 눌러 주세요. 로그인은 필요 없어요.
An opinionated standalone Markdown parser
저장소 README에서 가져옴
README 전체를 불러오는 중입니다. 아래는 저장된 발췌입니다.
markz — small, opinionated Markdown.
A standalone Markdown package for TypeScript/JavaScript: one fixed dialect (GFM's everyday syntax
without the parts that need backtracking, plus {…} attributes and elements, math, ${…} expressions and a metadata block), a compact flat source-mapped AST,
HTML output, and no configuration. Make the Markdown decision
once; use markz everywhere.
That is the whole API: parse, html, walk (with enter and exit, where enter returning
false skips a node's children), textContent (the text a node renders as) and position. None
of them takes options.README 전문 보기 ↗markz is a small, opinionated Markdown, and the one package that reads it, with no dependencies. It has one fixed dialect, a compact tree that maps every node back to the source, HTML output, and no options.
import { html, parse } from "@amitkaps/markz";
const page = html(markdown);
const doc = parse(markdown); // a read-only, source-mapped tree
console.log(doc.warnings); // what it didn't read, and what to write instead
The whole API is seven functions (parse, html, walk, textContent, ids, headings and position), the read-only Document and the frozen list of warning codes, in Reference. None of them takes options.
pnpm add @amitkaps/markz
Each release's package is also attached to its GitHub release. In Node, markz needs 26 or newer, the Node it's built and tested on. In the browser, it needs the browsers craftz names: Chrome and Edge from the last 12 months, Firefox's oldest supported ESR, and Safari from the last three majors. It is one ES module with no dependencies and no Node APIs, so the same file runs in Node, browsers and workers.
A page with no build step imports it from a CDN, which serves it minified:
<script type="module">
import { html } from "https://cdn.jsdelivr.net/npm/@amitkaps/[email protected]/+esm";
</script>
markz reads the Markdown people already write: # headings, _emphasis_, **strong**, - lists, fenced code, links, images, tables, tasks and ~~strikethrough~~. On top of that:
| To write | Write |
|---|---|
| Metadata | key: value lines between --- lines, at the very top |
| A class, id or attribute | {.class #id key=value open} above a block, or after a link |
| A styled word | [text]{.class} |
| An inline element | [Ctrl]{@kbd} |
| A block element | {@details} … {/details}, or [label]{@name /} |
| Math | $x$ in a line, or a $$ block |
| A value from code | ${name}, kept whole for the page to evaluate |
| HTML | a ```=html fence |
| A comment | <!-- … --> on lines of its own |
There is one way to write each thing. Forms that make a parser read ahead and change its mind, such as setext headings, reference links, raw HTML in text and indented code, aren't part of the language. They stay literal text and add a warning naming the form to write instead. markz never guesses what a document meant. Syntax has the whole language at a glance, and Grammar states it exactly.
```=html blocks, nothing a document says can put script on the page.markz reads its language, not every Markdown in the wild. Pasted or generated Markdown often uses forms it leaves out, like reference links, bare URLs, raw HTML, footnotes and named entities. Converting a document means fixing what doc.warnings lists.
markz builds on CommonMark and GFM, takes its cuts and attribute syntax from djot and its math from pandoc and GitHub, and uses micromark as the oracle its tests check against.