mirror of
https://github.com/showdownjs/showdown.git
synced 2024-03-22 13:30:55 +08:00
1.4 KiB
1.4 KiB
Prerequesites
Build
Building your clone of the repository is easy:
-
run
npm install
. -
run
npx grunt build
(seeGruntfile.js
). This command:- Cleans the repo.
- Checks code quality (JSHint and ESLint).
- Runs tests.
- Creates the distributable and minified files in the
dist
folder.
Test
A suite of tests is available which require Node.js. Once Node is installed, run the following command from the project root to install the dependencies:
npm install
Once installed, run tests from the project root:
npm test
You can easily add new tests:
- Create a markdown file (ending in
.md
) that contains the markdown to test. - Create a
.html
file with the same name as the markdown one from the previous step. Thishtml
file will automatically be tested when the tests are executed withmocha
.