quisquous/cactbot

eslint: cactbot-output-strings not detecting output properties from spread

wexxlee opened this issue · 0 comments

I mentioned this in my comment on PR #5534 , but it seems that cactbot-output-strings is not (or at least not properly) detecting output{} properties that are specified by a spread.

For example:

  • In golbez.ts, the 'Golbez Gale Sphere Directions' trigger calls output.clones!() and may pass in output.unknown!() as a value.
  • outputStrings includes a spread assignment -- ...Directions.outputStringsCardinalDir -- which contains a property of unknown: Outputs.unknown.
  • Unless unknown: Outputs.unknown is manually (and duplicatively) added to outputStrings, eslint will throw an error that there is no 'unknown' in 'output.'

Expected behavior: eslint should recognize properties assigned through a spread, and should not throw an error on a call to output.*!() if * is a valid property in outputStrings that is assigned through a spread.