Skip to content

removed good example from bad example #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions pages/docs/docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -1221,10 +1221,6 @@ That's because you often do see code like this:

In LightScript, accessing an index or property using `[]` requires an indent:

node
.children
[0]

node
.children
[0] // oops!
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you have a build running, you might try this and see what you think:

node		
.children		 
[0] // oops!

<!-- -->
node		
  .children		 
  [0]

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this breaks them into separate blocks

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm guessing some non-ascii invisible whitespace snuck in there somehow?

Regardless, the <!-- --> is a separator used for markdown, not something intended to be part of the lightscript. If you look for it in other parts of the file you'll see how it's used

Expand All @@ -1233,10 +1229,6 @@ The required indent is relative to the line that starts a subscript chain.

Note that this rule also applies to the "numerical index access" feature:

node
.children
.0

node
.children
.0 // oops!
Expand Down