Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X
Hi,
I found a very strange phenomenon, the ES6 syntax like "let", "const" work well normally. But in certain situation, the Lint will report error, see the attached picture.
The line #315 and #325 define the same variable name , but it's not the root cause. Changing to different variable name has the same error.
It seems the error occurs when the code lines exceeds about 310, but I'm sure .
Regards,
Sean
Hi @seanccc.
If you try declaring this statement once instead of twice, does the behavior change:
let intervalDays = interval;
Are there other errors elsewhere that may have a bearing on this one?
Regards.
--Sharon
Hi Sharon @slangley ,
Yes, for example, the code below doesn't declare the variable "j" twice, but still has the error.
Hi @seanccc.
I'm afraid there are a number of unknowns here since we can't see the full code. However, we would recommend reaching out to your Sales rep or contacting the Sales team to engage with a PTC consultant for assisting with a code review. They can recommend ways to debug and improve your code.
Regards.
--Sharon