浏览代码

Replaces broken tokens with an empty string

main
Eric Amodio 4 年前
父节点
当前提交
fdf1e7678a
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. +1
    -1
      src/system/string.ts

+ 1
- 1
src/system/string.ts 查看文件

@ -74,7 +74,7 @@ const pathStripTrailingSlashRegex = /\/$/g;
const tokenRegex = /\$\{(".*?"|\W*)?([^|]*?)(?:\|(\d+)(-|\?)?)?(".*?"|\W*)?\}/g;
const tokenSanitizeRegex = /\$\{(?:".*?"|\W*)?(\w*?)(?:".*?"|[\W\d]*)\}/g;
// eslint-disable-next-line no-template-curly-in-string
const tokenSanitizeReplacement = '$${this.$1}';;
const tokenSanitizeReplacement = "$${this.$1 ?? ''}";;
export interface TokenOptions {
collapseWhitespace: boolean;

正在加载...
取消
保存