Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
edemaine
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
5 ms
·
1.
▲
by
edemaine
2y ago
Do blocks in Civet are mainly to provide shielded scopes (with local declarations). They're currently also necessary to handle declarations (const/let) in the middle of expressions, but hopefully they won't be necessary event
2.
▲
by
edemaine
2y ago
Thanks for the report! This was tricky to track down, but I've got a fix: https://github.com/DanielXMoore/Civet/pull/1501
3.
▲
by
edemaine
2y ago
As an example, Solid's JSX compiler changes multiple times in a year. It's better to target JSX than the compiled form. There are also many JSX compilers. (Even React ships with at least two.)
4.
▲
by
edemaine
2y ago
Yes, Civet has taken a lot of syntactic inspiration from LiveScript. At this point, I think we have most of the good features, but we might be missing some. Let us know what you think! The big difference, of course, is that Civet fully supp
5.
▲
by
edemaine
2y ago
The JSX spec hasn't changed for almost 10 years, and I'd guess there will never be a JSX 2.0. On the other hand, ideas for a better JSX are plentiful (check out the issues on the JSX repo, for example). If the spec never changes,
6.
▲
by
edemaine
2y ago
Good question! I don't have hard numbers, but for larger files, I find that it can take on the order of a second to compile. It's still fast enough to get real-time feedback from TypeScript in VSCode, but it could definitely be fa
7.
▲
by
edemaine
2y ago
You can also turn off implicit returns in Civet if you don't like them. They also work well with TypeScript annotations: if you annotate a return value of `void`, then there's no implicit return. I agree it can be easy to make and
8.
▲
by
edemaine
2y ago
In case you wondered how Civet compared to CoffeeScript in these regards: * `is not` is the textual equivalent of `!==`. You can use `isnt` if you turn on the feature explicitly (or even the weird CoffeeScript `is not` behavior if you want
9.
▲
by
edemaine
2y ago
It's doing a few things at once: First line: * `{min, max} := Math` is a destructuring declaration. It's similar to the destructuring assignment `{min, max} = Math` (i.e., `min = Math.min; max = Math.max`), but also declares min a
10.
▲
by
edemaine
2y ago
But we are using indentation style; that's one of the major design principles. In Civet, the body of an "if" can be multiple lines, and it's clear (from indentation) what they're nested under. Also, the body of an &
11.
▲
by
edemaine
2y ago
We're definitely looking for ways to improve ways to specify types! I think destructured typing [ https://civet.dev/reference#destructured-typing ] is already quite useful, especially for React. On the readability side,
12.
▲
by
edemaine
2y ago
One of the Civet devs here. To me, the main benefit of Civet is the ability to rapidly add useful features to the language, while preserving all the benefits of TS (tooling, etc.). We're constantly coming up with ideas — from TC39 prop
13.
▲
by
edemaine
2y ago
Regarding the first question, I've gone ahead and implemented random build orders, so at least the two Ls in HELLO will usually produce different animations (depending on random choices). Designing completely different glyphs for the s
14.
▲
by
edemaine
2y ago
I find the back/forward buttons useful for undoing/redoing changes, so that I don't lose past cool designs / settings, though I can see it being a controversial approach. That said, there were definitely way too much his
15.
▲
by
edemaine
2y ago
Good idea! I've gone ahead and implemented this feature: if "obscure in URL" is turned on, the text won't be visible unless you focus on the textbox (e.g. to edit it).
16.
▲
by
edemaine
2y ago
I couldn't reproduce this bug. Perhaps the program you're using to display the GIF doesn't support the GIF frame delay feature? (E.g., Chrome seems to display them fine.) Feel free to open an issue on the repo if I'm mis
17.
▲
by
edemaine
2y ago
Thanks for the feature suggestion! I've gone ahead and implemented random valid stacking order. So if you reload the page, and enter text that repeats the same letter more than once, you will hopefully get different build orders (depen