Skip to content
/ ts-kata Public template

Simple TypeScript template for code katas.

License

Notifications You must be signed in to change notification settings

aivascu/ts-kata

Repository files navigation

TypeScript Kata template

Node CI

This repository is a simple TypeScript project for experimenting with coding Katas.

Summary

How to setup

There are two main ways to use this repository. You can setup the project locally or you could open it inside a Docker container, using VS Code.

Working locally

This project tries to keep a minimum of requirements. You'll need just two things to use it efficiently.

  • Node.js (v15.x)
  • Visual Studio Code

Next, inside the VS Code, go to the extensions packages and check the recommended extensions, by the repository.

At the moment there are three recommended extensions

Working inside container

To work inside an isolated container you'll need the following dependencies.

Next, inside VS Code, run the action Remote-Containers: Reopen in Container. All the necessary dependencies will be installed automatically inside the container, including the recommended extensions.

How to use

Since this is not a guide on how to practice conding katas, below are described only the steps necessary to build and run the tests.

Installing packages

Once you've setup the project, depending on the option you picked, you might want to install the dependencies. To install dependencies run the package install command inside the repository directory.

> npm install

Building

To build the project, you can invoke the following command inside your command line.

> npm run build

Running tests

To run the tests you can run the following command.

> npm run test

To run test continuously you can substitute test with watch-test.

If you have installed the recommended extensions inside VS Code, the tests will be run automatically on file save by the Jest extensions. Or you can choose to run them manually from the test explorer panel.

License

Copyright © 2021 Andrei Ivascu.
This project is MIT licensed.