hikaru-y / Edit-Field-During-Review-Cloze

Code for the anki addon Edit Field During Review Cloze

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

For add-on description, please see AnkiWeb page or the FAQ

Development

Setup

After cloning the project, run the following command

git submodule update --init --recursive
npm ci

The first command installs ankiaddonconfig as a git submodule, and the second command installs the npm dev dependencies of this project.

Updating typescript code

After editing code in ./src/ts, run npm run build to compile it to ./src/addon/web/editor/editor.js.

Tests & Formatting

This project uses mypy type checking for Python, and standardjs for formatting Javascript.

python -m mypy .
npx standard --fix

You will need to install the following python packages to run mypy:

python -m pip install aqt PyQt5-stubs mypy types-simplejson

This project doesn't use a strict python formatter. Even so, please make it look pretty enough :)

Building ankiaddon file

After cloning the repo, go into the repo directory and run the following command to install the git submodule ankiaddonconfig

git submodule update --init src/addon/ankiaddonconfig

After installing the git submodule, run the following command to create an efdrc.ankiaddon file

cd src/addon ; zip -r ../../efdrc.ankiaddon * ; cd ../../

About

Code for the anki addon Edit Field During Review Cloze

License:Other


Languages

Language:Python 45.4%Language:JavaScript 28.1%Language:TypeScript 21.2%Language:HTML 3.5%Language:CSS 1.9%