guansss / Theresa-wiki

一个明日方舟 Arknights 的wiki

Home Page:https://theresa.wiki/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Theresa.wiki

This repo is the frontend of https://theresa.wiki. An arknights wiki.

这是 Theresa.wiki 的前端。一个明日方舟的维基。目前,最重要的功能是查看明日方舟地图场景(大声)

这个 wiki 的定位不是完整(完整维基请去prts),更重要的是通过 杂技 获得 快乐

License

  1. MIT License
    • For all codes (not including ./src/arts/**), the license is MIT License, see LICENSE
  2. CC-BY-SA 4.0 License

Development and Contributing

PR is always welcome on dev branch.

You can use yarn dev to start your development environment.

ENV

.env.local is not loaded in docker, use .env.production.local instead

REDIS_URL is redis:// URL or rediss:// URL. You can leave it blank if not using redis cache. Use redis://redis/0 to specify database.

THERESA_STATIC: default value is https://static.theresa.wiki for production, and http://static.theresa.localhost for local testing

THERESA_S3: You can use https://raw.githubusercontent.com/Kengxxiao/ArknightsGameData/master/zh_CN/gamedata/ for testing. The limitation for s3.theresa.wiki is that it only provides the latest version of the data.

docker

docker build args

THERESA_WIKI_NO_BUILD_DYNAMIC_ROUTES=True to not build dynamic routes like /map/[stageId]. Building these dynamic routes need to fetch data while building. You can specify this with --build-arg THERESA_WIKI_NO_BUILD_DYNAMIC_ROUTES=true when using docker build.

Why removing data files?

In Dockerfile, there is one line RUN rm .next/standalone/.next/server/pages/zh/map.json. This is intend to ask nextjs to refetch data when startup, i.e. fetch data and server with latest data when accessing /map page.

Folder structure

src/arts Arts, including SVGs, used in this project
src/components common components
src/configurations configs
src/models models, including gamedata and react context
src/pages pages

Release process

For merging dev into master

  1. git checkout master
  2. git merge dev --no-ff
  3. git commit --amend Message: Release: x.x.x
  4. git tag x.x.x
  5. git checkout dev
  6. change changelog to next version
  7. git push --tags
  8. git push --all

About

一个明日方舟 Arknights 的wiki

https://theresa.wiki/

License:MIT License


Languages

Language:TypeScript 96.9%Language:JavaScript 2.3%Language:Dockerfile 0.7%Language:Shell 0.1%