Copy link to clipboard
Copied
In Visual Studio Code in the jsx file on all lines where #include is used, it gives a problem and suggests using ‘;’ at the end of the line.
What is causing this to happen?
1 Correct answer
Writing `//@include` instead of `#include` will prevent the error.
//@include '../Test/test-1.jsx'
main() ;
function main() {
// do something
}
Explore related tutorials & articles
Copy link to clipboard
Copied
Writing `//@include` instead of `#include` will prevent the error.
//@include '../Test/test-1.jsx'
main() ;
function main() {
// do something
}
Copy link to clipboard
Copied
Well, commenting on a line is clearly not a solution to the problem...
Copy link to clipboard
Copied
Have you actually tried this method? The code will be imported. Or is it not your goal to avoid errors and include the code?
Copy link to clipboard
Copied
Indeed, I didn't immediately notice that you used the @ symbol, and it works. But the disadvantage of this method is that visually the commented line blends in with the rest of the comments.

