[PLEASE TRANSLATE ME]
Install the following application to the environment for development.
Application name | Application version(Fill in only if specified) | Installation conditions |
---|---|---|
Node.js | 10.19.0 以上 | Required |
Visual Studio Code | If you use Visual Studio Code | |
yarn | When executing this program with yarn |
|
docker compose | When executing this program with docker compose |
|
Vagrant | When executing this program with Vagrant |
To use Visual Studio Code, install the following extension.
Extensions | Installation conditions |
---|---|
ESLint | Any |
Vetur | Any |
TSLint | Any |
Debugger for Chrome | Any |
Remote Development | When developing with Visual Studio Code and Remote Containers |
The command is executed in the working copy root directory.
[/PLEASE TRANSLATE ME]
[PLEASE TRANSLATE ME]
[/PLEASE TRANSLATE ME]
# install dependencies
$ yarn install
[PLEASE TRANSLATE ME]
After executing the following command, you can check the program under development by accessing http://localhost:3000 .
[/PLEASE TRANSLATE ME]
# serve with hot reload at localhost:3000
$ yarn dev
[PLEASE TRANSLATE ME]
You can disable accessibility auditing, which would make your local server faster.
[/PLEASE TRANSLATE ME]
# serve with hot reload at localhost:3000
$ yarn dev-no-axe
[PLEASE TRANSLATE ME]
[/PLEASE TRANSLATE ME]
Build the dependency again and run the program.
[PLEASE TRANSLATE ME]
After executing the following command, you can check the program under development by accessing http://localhost:3000 .
[/PLEASE TRANSLATE ME]
# serve with hot reload at localhost:3000
$ docker-compose up --build
[PLEASE TRANSLATE ME]
[/PLEASE TRANSLATE ME]
[PLEASE TRANSLATE ME]
Stop the program and execute the following command.
[/PLEASE TRANSLATE ME]
$ docker-compose run --rm app yarn install
[PLEASE TRANSLATE ME]
After executing the following command, you can check the program under development by accessing http://localhost:3000 .
[/PLEASE TRANSLATE ME]
# serve with hot reload at localhost:3000
$ vagrant up
[PLEASE TRANSLATE ME]
[/PLEASE TRANSLATE ME]
如同 Quick start: Try a dev container(外部連結)點擊左下角的 「Open Folder in Container」 後選擇 Repository 的資料夾路徑開始建立環境。
[PLEASE TRANSLATE ME]
You can check the program under development by accessing http://localhost:3000 after building the environment.
[/PLEASE TRANSLATE ME]
- 如果想要變更設定,請更改
.devcontainer/devcontainer.json
這隻檔案。 詳細請參考 devcontainer.json reference(外部連結)。 - Remote Container 啟動時擴充套件只有導入 「ESlint」、如果有必要,請在
.devcontainer/devcontainer.json
的extensions
中新增。 詳細的步驟請參考 Managing extensions(外部連結)。 - 如果要重新建立開發環境,請執行左下角的 「Rebuild Container」。
關於 process.env.GENERATE_ENV
這個值,生產環境為 'production'
,除此之外為 'development'
。
如果只想要在測試環境中執行的話,請利用這個值作為參考。
[PLEASE TRANSLATE ME]
When the branch listed in the left column of the table below is updated, the branch and website will be updated automatically.
branch | A branch where HTML is built and updated | Website updated |
---|---|---|
master |
production |
The production site https://stopcovid19.metro.tokyo.lg.jp/ |
staging |
gh-pages |
The staging site https://stg-covid19-tokyo.netlify.app/ |
development |
dev-pages |
The development site https://dev-covid19-tokyo.netlify.app/ |
[/PLEASE TRANSLATE ME]
只允許推送 Pull Request 到 development
。
在推送 Pull Request 時,請依照以下命名規則為您的分支命名
[PLEASE TRANSLATE ME]
Types of changes | Naming rules for the branch |
---|---|
新增功能 | feature/#{ISSUE_ID}-#{branch_title_name} |
Hotfix commit | hotfix/#{ISSUE_ID}-#{branch_title_name} |
[/PLEASE TRANSLATE ME]
[PLEASE TRANSLATE ME]
目的 | 分支 | 預覽用 URL | People who can make pull requests | 備註 |
---|---|---|---|---|
開發 | development | https://dev-covid19-tokyo.netlify.app/ | All developers | 基本上請推送 Pull Request 到這裡 |
正式版預覽 | staging | https://stg-covid19-tokyo.netlify.app/ | Only administrators | 對於正式版釋出前的最終確認,禁止管理員以外的人推送 Pull Request。 |
正式版 | master | https://stopcovid19.metro.tokyo.lg.jp/ | Only administrators | 禁止管理員以外的人推送 Pull Request |
[/PLEASE TRANSLATE ME]
目的 | 分支 | 預覽用 URL | 備註 |
---|---|---|---|
正式網站 HTML | production | https://stopcovid19.metro.tokyo.lg.jp/ | 生成靜態網站 HTML 的位置 |
正式版預覽 HTML | gh-pages | https://stg-covid19-tokyo.netlify.app/ | 生成靜態網站 HTML 的位置 |
OGP 工作用 | deploy / new_ogp | 無 | OGP 更新用 |