tweaking tsconfig.json

This commit is contained in:
evilchili
2026-08-10 11:48:01 -07:00
parent ba75124cc5
commit 464dd32b8f
7 changed files with 120 additions and 36 deletions
+11 -6
View File
@@ -1,10 +1,14 @@
"use strict";
/*
* hopdown.ts
* - Configurable markdown <=> HTML converter.
*/
import { defaultTags } from "./defaults";
import { Tokenizer } from "./tokenizer";
export function escapeHtml(source) {
Object.defineProperty(exports, "__esModule", { value: true });
exports.HopDown = void 0;
exports.escapeHtml = escapeHtml;
const defaults_1 = require("./defaults");
const tokenizer_1 = require("./tokenizer");
function escapeHtml(source) {
return source
.replace(/&/g, '&amp;')
.replace(/</g, '&lt;')
@@ -33,13 +37,13 @@ export function escapeHtml(source) {
* "</div>"
* );
*/
export class HopDown {
class HopDown {
tags;
referenceLinks = new Map();
tokenizer;
constructor(tags) {
this.tags = tags || defaultTags;
this.tokenizer = new Tokenizer(this.tags);
this.tags = tags || defaults_1.defaultTags;
this.tokenizer = new tokenizer_1.Tokenizer(this.tags);
}
/**
* Convert a markdown string to tokens.
@@ -376,3 +380,4 @@ export class HopDown {
return result;
}
}
exports.HopDown = HopDown;