tscad is in early development
DocsIntroductionWhat is tscad?

What is tscad?

Inspiration

I want to have an open source parametric CAD solution with good developer tooling. I draw my inspiration from seeing other open source projects doing great work on the CAD front, but lacking the DX1 a modern developer expects:

OpenSCAD

OpenSCAD is great because it has tons of features and a pretty active community to help resolve issues.

Sadly, they invented their own programming language and their own IDE, which lacks many basic features like autocompletion and cannot compete with modern AI-assisted IDEs. You can use your own IDE (e.g., VS Code with some plugins) and use the OpenSCAD app just for rendering, but it still uses its own programming language, and documentation is sparse. Also, performance can be really bad for some models.

JSCAD

Similar to OpenSCAD, but they use JavaScript for coding.

They lack the same DX essentials: Their own IDE (actually a website) has a very basic code editor with no autocompletion as well. The model preview is actually fine, but the documentation is not really up-to-date and is very basic. Using a "real" IDE helps a lot and the command line application is really handy for scripting. The API is stable, so we'll (re)use many of their APIs.

I just want to add once more that these projects are my main inspiration and I totally admire these developers for their work. You laid the groundwork for this project.

Goals

In order to achieve a better developer experience, I want to focus on these primary goals to increase the overall developer experience with parametric CAD:

Modern Programming

I want to use TypeScript in this project. It's a solid programming language with excellent tooling. You can also run it in a browser and use it on basically any OS, which is great for integrating other tools/services.

Since TypeScript is basically JavaScript with types, I also want to support JavaScript and the entire npm ecosystem to make things modular.

Flexible Tooling

First and foremost, I want to provide a stable, strongly typed TypeScript API for parametric CAD with good documentation. It should basically have the same functionality as JSCAD, just in TypeScript. A basic command line interface can be used to generate exports etc.

At this point, users can create CAD models and e.g., export them to STL.

Next, I want to create a flexible preview based on web technology. This way we can easily run it in a browser, on a server, or in a desktop app (with something like Tauri).

We can then integrate this preview into the command line application to build and preview our models. It basically runs a web server that updates the page when the underlying code changes.

Now users are able to preview their models as they code. You can even use an in-IDE browser (like VSCode's Simple Browser) to preview code and preview side by side.

Now we can also use the preview and put it in an online web application together with an online IDE.

Now we're talking: We're basically feature-complete with OpenSCAD and JSCAD.

Good Documentation

Alongside the online IDE, I want to host extensive documentation with good search functionality.

Footnotes

  1. developer experience