TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Tackle Complexity in Typescript apps with TSMC

4 点作者 svallory超过 11 年前
TSMC allows you to configure the modules and submodules (as well as their inner dependencies) you want to get out of your library&#x2F;app and compile them giving you separately packaged modules and submodules.<p>Let&#x27;s say you have a modals module, inside your ui namespace which is one of many namespaces inside your awesomejs lib. Driven by your config, tsmc will give you a awesomejs-ui-modals.js, an awesomejs-ui.js (which contains everything inside ui, including modals) and a awesomejs.js (which includes ui and everything else). For each package it will also give you a declaration (.d.ts) file and a sourcemap (.js.map) file. AFAIK, this is the best way available to have your source code compiled into a big combine package as well as fine grained modules.

2 条评论

svallory超过 11 年前
Cool @paf31, please let me know how it goes!
paf31超过 11 年前
Neat! I&#x27;ll try this out today.