You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
はじめに Reactを書くとき、私たちはほぼ必ずJSX(TSX)で書くと思います。 そんなJSX(TSX)の代替となるようなTSRXというTypeScriptのスーパーセット言語がアルファ版として公開されていて、ちょっと面白そうだったので触れてみました。 TSRXとは? TSRXは、元ReactコアエンジニアであるDominic Gannawayさんが開発しているTypeScriptのスーパーセット言語です。 Gannawayさんは現在RippleというUIライブラリを開発しており、TSRXはもともとRippleのなかで使われていた構文です。それをフレームワーク非依存として切り出したのがTSRXという出自です。 RippleとTSRXの関係としては、RippleがReactやVue.jsと同じ「UIライブラリ」として動作します。TSRXはUIライブラリの1段上のレイヤーに位置するテンプレー
export type Rectangle = { height: number; width: number; }; export const Rectangle = { from(height: number, width: number): Rectangle { return { height, width, }; }, }; // Rectangleという宣言が型と値の両方で使える! const rectangle: Rectangle = Rectangle.from(1, 3); サバイバルTypeScriptを読んだ方は、型(Type)と値(Value)を同じ名前で定義するテクニックとしてご存知かもしれません。 実はこれ、名前空間(namespace)も加えた 「三重定義」 が可能なんです。 今回は、この「三重定義」を活用することで実現できる、Reactコンポーネントの柔軟
Flue is The Agent Harness Framework. If you know how to use Claude Code (or Codex, OpenCode, Pi, etc)... then you already know the basics of how to build agents with Flue. Flue is a TypeScript framework for building the next generation of agents, designed around a built-in agent harness. It's like Claude Code, but 100% headless and programmable. There's no baked-in assumption like requiring a huma
TypeScript は、ワークフローのような処理を少量のコードで書けます。 たとえば「あるノードから次のノードへ進む」という処理だけなら、数十行で実装できます。 一方で、実装の規模が大きくなると、次のような不安が出てきます。 ワークフローを扱う関数の間で、ワークフローに期待する意味がずれていないか テストしていない入力で、想定外の振る舞いをしないか 実装を変更したとき、以前満たしていた性質を壊していないか この記事では、非常に小さなワークフローを題材にして、定理証明支援系 Lean を使い、TypeScript 実装が Lean で書いた基準となるモデルと一致するかを検査する方法を紹介します。 この記事で行うのは、TypeScript の実装そのものを Lean で完全に証明することではありません。 より具体的には、以下の構成になっています。 TypeScript でワークフローを実装す
v0.5.306 — generational GC + lazy JSON tape default, faster than Node and Bun on most benchmarks One Codebase. Every Platform. Native Performance.Perry compiles TypeScript to native GUI and CLI apps on macOS, iPadOS, iOS, Android, Linux, Windows, watchOS, tvOS, WebAssembly, and the Web. No runtime. No Electron. Just native binaries.
Pure JavaScript/TypeScript library for multiline text measurement & layout. Fast, accurate & supports all the languages you didn't even know about. Allows rendering to DOM, Canvas, SVG and soon, server-side. Pretext side-steps the need for DOM measurements (e.g. getBoundingClientRect, offsetHeight), which trigger layout reflow, one of the most expensive operations in the browser. It implements its
Polyglot とは、複数のプログラミング言語 (あるいはより一般に、何らかのファイルフォーマット) で解釈できるプログラムのことで、多言語話者にちなんでこの名前がつけられています。Polyglotはしばしば、プログラミングに関する非実用的な探求として遊ばれます。 TypeScriptはJavaScriptのスーパーセットであるため、JavaScriptコードは自然にJavaScriptとTypeScriptコードのpolyglotとみなせます。しかしこれでは面白くないので、本稿では以下の条件を満たすpolyglotを提示します。 JavaScriptとして実行したときと、TypeScriptとして実行したときで、全く異なる処理が実行されること。 TypeScriptとして型エラーが生じないこと。 答え 本稿で提示する解答例は以下のコードです。 new (f())<0>/[/*]/ fu
import * as np from 'numpy-ts'; // Array creation with dtype support const A = np.array([[1, 2], [3, 4]], 'float32'); const B = np.ones([2, 2], 'int32'); // Broadcasting and chained operations const result = A.add(5).multiply(2); // Linear algebra const C = A.matmul(B); const trace = A.trace(); // Reductions with axis support const colMeans = A.mean(0); // [2.0, 3.0] // NumPy-style slicing with st
ESLint has been the leading web ecosystem linter for a decade. Its dominance is being challenged by new native speed linters such as Biome and Oxlint that implement blazing fast linting using native speed languages. Even TypeScript’s source is being ported from TypeScript to Go. Yet, this Flint project -a new, experimental linter- is implemented in TypeScript rather than Go or Rust. Why does Flint
TypeScript 7で消えるtsconfigのレガシー設定。target: es5やbaseUrlにサヨウナラ TypeScript 7ではtarget: es5やbaseUrlといった長年のレガシーな設定が削除され、strict: trueが標準になるなどデフォルトの挙動が変更されます。本記事では、消えるレガシーな設定や挙動が変わる主要な設定について、設定の基本知識から代替案までを解説します。ご自身のtsconfig.jsonを更新する際の参考になれば幸いです。 TypeScript 7とは そもそもTypeScript 7ではコンパイラーが大きく変わります。現在のTypeScriptのコンパイラーはTypeScriptで記述されていますが、TypeScript 7ではGO言語によるネイティブコンパイラー「tsgo」となります。コンパイル速度が10倍向上するという公式発表があり、実際
Cap'n Web is a spiritual sibling to Cap'n Proto (and is created by the same author), but designed to play nice in the web stack. That means: Like Cap'n Proto, it is an object-capability protocol. ("Cap'n" is short for "capabilities and".) We'll get into this more below, but it's incredibly powerful. Unlike Cap'n Proto, Cap'n Web has no schemas. In fact, it has almost no boilerplate whatsoever. Thi
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く