TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Build a Lightweight Code Generator with TypeScript and JSON Imports

21 pointsby philk10over 1 year ago

3 comments

fatih-erikliover 1 year ago
&gt; That structure is likely to change during the lifetime of your software.<p>I don&#x27;t understand this sentence. If the structure is going to change over the time, it means you will need to regenerate the whole system, plus you will apply the changes that you made on the generated code to the newest generated version. So it isn&#x27;t a valid case for generating code.
评论 #38194584 未加载
评论 #38194563 未加载
martypittover 1 year ago
Great post. Bonus points for introducing TSX (the other TSX), which also seems really cool.<p>Also, importing JSON in typescript is another cool thing I learnt about.<p>Thanks for writing this up!
pyrolisticalover 1 year ago
Interesting. Maybe this would work with OpenApi (aka swagger) schema