Chuyển đến nội dung chính

dsh-shiki

Đã xác minh

@ch4acko3/dsh-shiki · v0.1.2 · MIT · Giao diện web

Shared Shiki engine service for DeepSeek Harness Web plugins

Cài đặt

dsh plugin add @ch4acko3/dsh-shiki

Xác nhận layer đã áp bằng dsh --profile default --dump-config — xem hướng dẫn cài plugin.

Mã nguồn

Phát hành lên npm mà không có repository công khai. Hãy kiểm tra nội dung package trước khi cài.

Thẻ

Readme

@ch4acko3/dsh-shiki

A browser-side Cordis service that owns one lazily created Shiki engine for DeepSeek Harness Web plugins.

export const inject = ['shiki']

export function apply(ctx) {
  const result = ctx.shiki.tokenize({
    code: 'const answer = 42',
    language: 'ts',
  })
  console.log(result.lines)
}

resolveLanguage() accepts common aliases, including patch for the bundled diff grammar. tokenize() requires a supported language and returns Shiki tokens using DSH's --shiki-* CSS variables. Its lineEndings field preserves the source's original LF, CRLF, or CR separators.