brendan-duncan / wgsl_reflect

A WebGPU Shading Language parser and reflection library for Javascript.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fantastic project!

ziriax opened this issue · comments

Thanks for sharing this project.

Maybe I be so free to ask why it wasn't written in Typescript?

Thanks!

It wasn't written in Typescript because I prefer writing in JS. TS definitions can always be added, which someone started. But for myself, I just prefer JS, I get enough compiling from my day job.

I started rewriting the library in typescript.

I'm learning Typescript as I go, and I'm still trying to figure out the best practices for TS, but I have a rough draft of the rewrite in the branch: https://github.com/brendan-duncan/wgsl_reflect/tree/ts

I use a lot of different languages daily, and to me, TS feels very rough. I wish it had the nullability features of Swift or Dart. Oh well, at least it's more structured than JS, though I really enjoy the pure dynamic nature of JS.

Which nullability feature do you need? Does it help if you enable strict mode in tsconfig.json?

Strict mode would be good, I haven't played much with the tsconfig settings yet. Unfortunately I don't have any time at the moment to get back to this project, family health issues has been consuming all of my time. If you see something that can be improved, please feel free.