Eslint review, round 1 (#58168)
This commit is contained in:
@@ -37,7 +37,7 @@ const notRegex = /(?:^|\s)not\s/
|
||||
// native Liquid `if` block tag. It has special handling for statements like {% ifversion ghes < 3.0 %},
|
||||
// using semver to evaluate release numbers instead of doing standard number comparisons, which
|
||||
// don't work the way we want because they evaluate 3.2 > 3.10 = true.
|
||||
export default class extends Tag {
|
||||
export default class Ifversion extends Tag {
|
||||
tagToken: TagToken
|
||||
branches: Branch[]
|
||||
elseTemplates: Template[]
|
||||
|
||||
@@ -29,7 +29,7 @@ export const Prompt: LiquidTag = {
|
||||
},
|
||||
|
||||
// Render the inner Markdown, wrap in <code>, then append the SVG
|
||||
render: function* (scope: any): Generator<any, string, unknown> {
|
||||
*render(scope: any): Generator<any, string, unknown> {
|
||||
const content = yield this.liquid.renderer.renderTemplates(this.templates, scope)
|
||||
|
||||
// build a URL with the prompt text encoded as query parameter
|
||||
|
||||
@@ -53,7 +53,7 @@ export const Spotlight = {
|
||||
stream.start()
|
||||
},
|
||||
|
||||
render: function* (scope: Record<string, unknown>): Generator<unknown, unknown, unknown> {
|
||||
*render(scope: Record<string, unknown>): Generator<unknown, unknown, unknown> {
|
||||
const output = yield this.liquid!.renderer.renderTemplates(this.templates, scope)
|
||||
|
||||
return yield this.liquid!.parseAndRender(template, {
|
||||
|
||||
@@ -66,7 +66,7 @@ export const Tool = {
|
||||
},
|
||||
|
||||
// scope is a Liquid scope object, Generator yields/returns Liquid template values - no TypeScript definitions available
|
||||
render: function* (scope: any): Generator<any, any, any> {
|
||||
*render(scope: any): Generator<any, any, any> {
|
||||
const output = yield this.liquid.renderer.renderTemplates(this.templates, scope)
|
||||
return yield this.liquid.parseAndRender(template, {
|
||||
tagName: this.tagName,
|
||||
|
||||
Reference in New Issue
Block a user