Skip to content

notwindstone/anisun

Repository files navigation

Favicon

An extension-based web app for exploring anime

The goal of this project is to replicate a Tachiyomi-like experience for watching anime on a website.

English | Русский

stars-badge next-js-badge typescript-badge

Screenshots

Home page screenshot (desktop, dark theme) Home page screenshot (desktop, light theme) Home page screenshot (mobile, dark theme) Home page screenshot (mobile, light theme)

More

Expand
Library page screenshot (desktop, dark theme) Extensions page screenshot (desktop, dark theme) Account page screenshot (desktop, dark theme) Anime page screenshot with Example Svelte plugin (desktop, dark theme) Anime page screenshot with Example Vue plugin (desktop, dark theme) Anime page screenshot with Anime Trailers plugin (desktop, dark theme) Account page screenshot with NSO theme plugin (desktop, light theme)

Features

  • Extensions in JS (visit docs.anime.tatar for more info)
  • Anilist and Shikimori integrations
  • Search anime by filters
  • Watching history
  • Localization
  • Theme customization

Performance

Even though this website is written in React, I think I still managed to achieve great performance. I tried to make it as smooth as possible while dealing with the monstrous re-rendering nature of React. It should work perfectly on mobile phones too, both in Firefox and Chromium-based browsers.

PageSpeed Insights

Expand

psi-home

psi-library

psi-extensions

psi-account

Web page size

Expand

web-page-size

Self-Hosting

Vercel

Expand steps

Click the button

Vercel

Navigate to Project -> Settings -> Environment Variables and then add values to the following keys:

  1. NODE_ENV = production

  2. (Optional) HOST_URL = https://your-domain-here.vercel.app - change to your domain that you are going to use in the Shikimori/Anilist integrations

  3. (Optional) SHIKIMORI_CLIENT_ID = yourOwnOAuth2ClientID - only if you want to enable integration with Shikimori

  4. (Optional) SHIKIMORI_SECRET_KEY = yourOwnOAuth2SecretKey - only if you want to enable integration with Shikimori

  5. (Optional) ANILIST_CLIENT_ID = yourOwnOAuth2ClientID - only if you want to enable integration with Anilist

  6. (Optional) ANILIST_SECRET_KEY = yourOwnOAuth2SecretKey - only if you want to enable integration with Anilist

Note: LRU cache might not work as expected, because serverless environments tend to spin down on low load.

Local

Expand steps

If you don't want to use a vercel/netlify/other serverless environment.

Preparations

You need to install:

  • Node.js
  • A package manager for node.js (e.g. bun)
  • Git

After successful installation clone this repository by running:

git clone https://github.com/notwindstone/anisun

Now you can install all project dependencies with bun i

Before you build/start this project, create a .env.local file, follow the .env.example example file and fill in those environmental variables:

  1. NODE_ENV = production - for development builds change to development

  2. (Optional) HOST_URL = https://your-ip-or-domain-here - change to your domain that you are going to use in the Shikimori/Anilist integrations

  3. (Optional) SHIKIMORI_CLIENT_ID = yourOwnOAuth2ClientID - only if you want to enable integration with Shikimori

  4. (Optional) SHIKIMORI_SECRET_KEY = yourOwnOAuth2SecretKey - only if you want to enable integration with Shikimori

  5. (Optional) ANILIST_CLIENT_ID = yourOwnOAuth2ClientID - only if you want to enable integration with Anilist

  6. (Optional) ANILIST_SECRET_KEY = yourOwnOAuth2SecretKey - only if you want to enable integration with Anilist

Development

You can run this app in development mode using bun dev

It will be much slower than the production build, because development mode is intended to use only for development. It builds everything on-demand and supports Hot Module Replacement (HMR).

Termux

To run this project in development mode, use bun run dev:termux

Production

Build this app by running bun run build

Now you can start it by bun run start

If you want to expose your website instance to others, then it is not production-ready yet. You need to install a reverse-proxy like Caddy first.

After you have installed Caddy, you need to rename Caddyfile.example in the root of repository to Caddyfile and change example.com in the file to your domain (anime.tatar in my case). Then just restart it by running caddy stop and caddy start in the terminal.

Be sure you are running caddy start in the repository directory, otherwise Caddy will not use your configuration file.

With Caddy you can also use a Cloudflare proxied DNS for DDoS protection, you just need to set SSL/TLS encryption mode to Full (Strict) and point A-record to your host machine IP.

Contributing

Contributions are welcome! Check CONTRIBUTING.md

Contact

Star History

star-history-chart

License

license-badge

Disclaimer

The developer of this application does not have any affiliation with the content providers available, and this application hosts zero content.

Acknowledgments

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •