Reputation: 86
I'm getting into using Julia from usually using R/Rstudio. One of Rstudio's most useful features was its ability to automatically indent code when I press enter while typing out. E.g. I can press enter after typing out "3," and the end of the vector and it will automatically indent like so:
matrix(c(1, 2, 3,
4, 5, 6),
2, 3)
Is there a way to replicate this functionality with Julia/VScode? E.g. type out the following and/or other functions without manually entering spaces
array_1 = [1 2 3:
4 5 6]
Upvotes: 3
Views: 364
Reputation: 7694
If you manually indent the second row of the matrix, then subsequent rows will be indented automatically.
Upvotes: 3
Reputation: 281
If you press <enter>
after the [
, all indentation will be automatic thereafter
array_1 = [
1 2 3;
4 5 6
]
Upvotes: 3