Skip to content
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

RFC Blogpost for indented syntax #1260

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

jamesnw
Copy link
Contributor

@jamesnw jamesnw commented Nov 26, 2024

No description provided.

Copy link

netlify bot commented Nov 26, 2024

Deploy Preview for sass-lang ready!

Name Link
🔨 Latest commit 2002663
🔍 Latest deploy log https://app.netlify.com/sites/sass-lang/deploys/674727f23fadaa0007c4e4a0
😎 Deploy Preview https://deploy-preview-1260--sass-lang.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

@jgerigmeyer jgerigmeyer left a comment

Choose a reason for hiding this comment

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

👍

source/blog/044-rfc-indented-syntax.md Outdated Show resolved Hide resolved
Comment on lines 54 to 66
```sass
@each $item in ¹
1 2 3
.item-#{ ²
$item
}
content: $item * ³
10
```

1. A statement can't end after the word "in" in an `@each` statement.
2. A statement can't end inside the curly braces in an interpolation.
3. A statement can't end after a multiplication operator.
Copy link
Contributor

Choose a reason for hiding this comment

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

I think these references might be easier to parse if they used line numbers instead of superscript. Or I'm not sure if there's a better way to make it clear that they're not part of the code example?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Line numbers made it harder to follow, I think.

I'll push a version with inline comments-
image

Here's the original-
image

source/blog/044-rfc-indented-syntax.md Outdated Show resolved Hide resolved
Comment on lines +48 to +50
linebreak is treated as whitespace. This means that if the parser can't tell
whether or not a linebreak is intended to end a statement, it will end the
statement.
Copy link
Contributor

Choose a reason for hiding this comment

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

Would it be helpful to also include a code example showing the "parser can't tell" path?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added in 2002663

@jamesnw
Copy link
Contributor Author

jamesnw commented Nov 27, 2024

@nex3 This is ready for review. It currently has today's date (11-27) but given the holiday, I could update that to next week if you'd prefer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants