Commit Graph

5 Commits

Author SHA1 Message Date
Kaz Wesley
2b3bd2cc90
Move documentation into documentable types (#11441)
Move documentation into documentable types (implements #11302).

# Important Notes
GUI:
- Distinguish expression and statement
- `Ast.Ast` is still present, as the base class for AST objects. Most references to `Ast.Ast` are now references to `Ast.Expression`. Operations on blocks use `Ast.Statement`.
- `Ast.parse` has been replaced with: `Ast.parseExpression`, `Ast.parseStatement`, and `Ast.parseBlock`
- `syncToCode` is internally context-aware; it parses the provided code appropriately depending on whether its AST is an expression, a statement, or the top level of a module.
- Remove `wrappingExpression` / `innerExpression` APIs: Wrapper types have been eliminated; modifier lines are now fields inside parent types.
- Simplify AST printing:
- Fully implemented autospacing in `concreteChildren` implementations; the type returned by `concreteChildren` now ensures that spacing has been fully resolved.
- Eliminate `printBlock` / `printDocs`: `concreteChildren` is now aware of indentation context, and responsible for indentation of its child lines.
- The `Pattern` type is now parameterized to identify the AST type it constructs. The `Pattern.parseExpression` function helps create a `Pattern<Expression>`.
- Refactor `performCollape` for testability.
- e2e tests: Improve table viz test: It still doesn't pass on my Mac, but these changes are necessary if not sufficient.

Compiler (TreeToIr):
- An expression in statement context is now found in an `ExpressionStatement` wrapper.
- Documentation for a `Function` is now found inside the function node.
- Deduplicate some polyglot-function logic.
2024-11-04 15:33:53 +00:00
Sergei Garin
fae18c0a04
Add eslint-react-compiler (#11404)
* Add React compiler eslint rules and fix issues across reusable components

* Fix compiler errors

* Remove fail-on-warnings for eslint

* Set max-warnings to 41 to match the amount of warnings introduced by react-compiler

* Add comment for lint task
2024-10-28 15:58:41 +03:00
somebody1234
5faddf52f0
Fix ESLint errors, add some docs (#11339)
- Fix ESLint errors
- Add documentation for *some* functions with blank documentation

# Important Notes
None
2024-10-21 12:56:39 +00:00
Adam Obuchowicz
d1ee7fadce
Remove download font scripts (#11317)
The fonts were added (by mistake) anyway, but they are rarely changed, and the scripts add unnecessary complexity.

This also fixes some post- #11287 problems.
2024-10-14 16:11:42 +00:00
Adam Obuchowicz
4a249688e8
Unify Frontend App (#11287)
Fixes #10668
Fixes #8484

Summary of changes:
* `gui2` and `dashboard` are merged to `gui` directory. Various configs were merged (package.json, playwrigth, TS...). The src and e2e directories are split to `dashboard` and `project-view` for now.
* E2E tests run two servers on different ports. The tests are organized in projects. This is also to be changed soon, as we plan to [use better mocking in GUI/ProjectView](#9726)
* ESlint configs were merged to central `eslint.config.mjs`, and that file was moved to repository root. We kept the dashboard lints, but they can be relaxed. The dashboard code was changed to meet GUI lints.
* Also, the versions of linter plugins were bumped, and code fixed.
* The ide-desktop/client no longer has `dashboard` dependency - the only type used there was moved to common package.
* `common` package moved to `app`.
2024-10-11 18:23:02 +00:00