Next.js : インストール2025/09/12 |
|
React ベースの Web 開発フレームワーク Next.js のインストールです。 |
|
| [1] | |
| [2] | 任意の一般ユーザーで Next.js テストアプリケーションを作成します。 |
|
# Next.js アプリケーション [test-app] 作成 debian@dlp:~/testproject3$ npx create-next-app test-app Need to install the following packages: create-next-app@15.5.3 Ok to proceed? (y) y Would you like to use TypeScript? … No / Yes Would you like to use ESLint? … No / Yes Would you like to use Tailwind CSS? … No / Yes Would you like to use `src/` directory? … No / Yes Would you like to use App Router? (recommended) … No / Yes Would you like to customize the default import alias? … No / Yes Creating a new Next.js app in /home/debian/testproject3/test-app. Using npm. ..... ..... added 335 packages, and audited 336 packages in 36s 137 packages are looking for funding run `npm fund` for details found 0 vulnerabilities Initialized a git repository. Success! Created test-app at /home/debian/testproject3/test-app
debian@dlp:~/testproject3$
cd test-app
# 開発用サーバーを起動 debian@dlp:~/testproject3/test-app$ npm run dev > test-app@0.1.0 dev > next dev --turbopack ▲ Next.js 15.5.3 (Turbopack) - Local: http://localhost:3000 - Network: http://10.0.0.30:3000 ✓ Starting... Attention: Next.js now collects completely anonymous telemetry regarding usage. This information is used to shape Next.js' roadmap and prioritize features. You can learn more, including how to opt-out if you'd not like to participate in this anonymous program, by visiting the following URL: https://nextjs.org/telemetry ✓ Ready in 939ms # ビルド & プロダクションモードでサーバーを起動 debian@dlp:~/testproject3/test-app$ npm run build > test-app@0.1.0 build > next build --turbopack ▲ Next.js 15.5.3 (Turbopack) Creating an optimized production build ... ✓ Finished writing to disk in 5ms ✓ Compiled successfully in 3.4s ✓ Linting and checking validity of types ✓ Collecting page data ✓ Generating static pages (5/5) ✓ Collecting build traces ✓ Finalizing page optimization ..... ..... |
| 任意のクライアントコンピューターで表示された URL に Web アクセスして、以下のようなページが表示されれば OK です。 |
|
| Sponsored Link |
|
|