Skip to content
ChartDeck ChartScript docs Account Open the terminal

CS2722

error The style property prop does not apply to kind.

#What it means

The style property exists, but not for this kind of style. For example, a font belongs to text, labels, markers, boxes and tables, not to a plot line.

#Typical cause

  • A property copied from another kind of style.

#How to fix it

Remove the property or move it to a style of the right kind. The reference lists the properties of each kind.

#Example

ChartScriptError: CS2722
//@chartscript 1
indicator("Styled close", { overlay: true })
const main = style.plot("Main line", { font: font.mono })
plot(close, { look: main })

Fixed

ChartScriptOpen in editor
//@chartscript 1
indicator("Styled close", { overlay: true })
const main = style.plot("Main line", { width: 2 })
plot(close, { look: main })
  • CS2713 — name has no style property prop.
  • CS2725 — look cannot be used on kind.

The ChartScript documentation is in English for now; translations will follow.