Skip to content

Commit

Permalink
refactor(jsx): add override to toStringToBuffer in classes extend…
Browse files Browse the repository at this point in the history
…ing `JSXNode` (honojs#3505)
  • Loading branch information
yusukebe authored and TinsFox committed Oct 28, 2024
1 parent b347b8c commit 7f2b62c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/jsx/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ export class JSXNode implements HtmlEscaped {
}

class JSXFunctionNode extends JSXNode {
toStringToBuffer(buffer: StringBufferWithCallbacks): void {
override toStringToBuffer(buffer: StringBufferWithCallbacks): void {
const { children } = this

const res = (this.tag as Function).call(null, {
Expand Down Expand Up @@ -284,7 +284,7 @@ class JSXFunctionNode extends JSXNode {
}

export class JSXFragmentNode extends JSXNode {
toStringToBuffer(buffer: StringBufferWithCallbacks): void {
override toStringToBuffer(buffer: StringBufferWithCallbacks): void {
childrenToStringToBuffer(this.children, buffer)
}
}
Expand Down

0 comments on commit 7f2b62c

Please sign in to comment.