comptime.ts is a TypeScript compiler that enables compile-time evaluation of expressions marked with 'comptime', moving computations from runtime to build time for performance optimization. It supports Vite and Bun bundlers, offers CLI and API usage, and can handle promises and complex expressions. The tool requires
Table of contents
🔗 Contents🔗 What is comptime.ts?🔗 Examples🔗 Installation🔗 Usage🔗 Forcing comptime evaluation of arbitrary expressions (and resolving promises)🔗 Running code after comptime evaluation🔗 How it Works🔗 Limitations🔗 Best Practices🔗 Troubleshooting🔗 Supporting the project🔗 License1 Comment
Sort: