Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

React's new <ViewTransition /> doesn't seem to work

オープン
#559 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
活発
技術スタック
react, typescript
領域
frontend

調査の方向性

提供された TypeScript の aroundNav 例と Router 統合から始め、React の ViewTransition ドキュメントを使って、flushSync ありとなしのナビゲーションを再現します。Chrome の view-transition エントリとアニメーションパネルを調べます。トランジションが表示されない理由を特定し、検証済みの修正または必要な使用方法を文書化できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

I've been trying to get React's upcoming component to work, which is a wrapper over the browser view-transitions API with some niceties. However, I was not able to get this to work. I've replicated the example in the docs for the view-transitions API, and created an aroundNav, except instead of invoking it with document.startViewTransition, I use react's startTransition as they've described in their docs. I tried this both with and without the flushSync. In none of these scenarios could I get it work. Has anyone tried this yet? Any idea how I can get it to work?


const aroundNav: AroundNavHandler = (navigate, to, options) => {
	startTransition(() => {
		flushSync(() => {
			navigate(to, options);
		});
	});
};

const App = () => {
	return (
		<StrictMode>
			<Router aroundNav={aroundNav}>
				// ...

I am seeing something to do with viewtransitions flash near the <html> node in Chrome's web inspector's elements panel, but it goes away too soon know what it says, but I suspect it's something React is doing. However in the animations panel in Chrome, I don't see any animation running, but I expect to see the standard fade animations provided by the default view-transitions API.

Any idea what I might be doing wrong?

主要言語
TypeScript
スター
7.9k
フォーク
193
平均マージ
9分
マージ済み PR(30日)
1

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

molefrog/wouter のほかの issue

molefrog/wouter の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。