Giter VIP home page Giter VIP logo

ts-nextbook-app's Introduction

TypeScriptとReact/Next.jsでつくる実践Webアプリケーション

TypeScriptとReact/Next.jsでつくる実践Webアプリケーション」のサンプルアプリ

サンプルアプリ

初版からのアップデート

環境

  • Node.js: 16.14.0
  • Next.js: 12.2.3
  • React: 18.2.0

インストール

npm install

環境変数の設定

.envを開く

API_BASE_URL=<バックエンドAPIへのベースURLの設定>
NEXT_PUBLIC_API_BASE_PATH=/api/proxy

開発サーバー起動

開発サーバーの起動し、http://localhost:3000/ にアクセス

npm run dev

Storybook起動

Storybookを起動し、http://localhost:6006/ にアクセス

npm run storybook

テスト実行

ユニットテスト実行

npm run test

ソースコードリンター・フォーマッター

ソースコードをリンターでチェック

npm run lint

ソースコードをフォーマッターで整形

npm run format

ディレクトリ構成

簡単にディレクトリ構成を以下に説明します。

├── .editorconfig
├── .env <-- 環境変数
├── .env.production <-- 本番用環境変数
├── .eslintrc.json <-- ESLint設定ファイル
├── README.md
├── jest.config.js <-- Jestの設定ファイル
├── jest.setup.js <-- テストファイルが実行される前に走る
├── next-env.d.ts
├── next.config.js <-- Next.js設定ファイル
├── package-lock.json
├── package.json
├── public
├── src
│   ├── components <-- Presentational Components
│   ├── containers <-- Container Compoments
│   ├── contexts <-- React Context
│   ├── pages <-- Next.jsのページ
│   ├── services <-- Web API Client
│   ├── themes <-- styled-componentsのテーマ
│   ├── types <-- 型定義
│   └── utils <-- 汎用関数
└── tsconfig.json

ts-nextbook-app's People

Contributors

masakinihirota avatar nodawep avatar tamanyan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.