Skip to content

A simple word count application to introduce students to TypeScript 🔡

Notifications You must be signed in to change notification settings

mihi-r/word-counter-ts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Word Counter - A TypeScript Lesson

Word Counter is a simple word count application created to introduce students involved in the Technology Committee in CEAS Tribunal to TypeScript. This lesson acts as a part 2 to the original JavaScript version of the lesson.

Functionality

Primary

The words to count input box will accept sentences and once the count button is pressed, the sentence will be parsed by the spaces in the text while filtering out punctuation (aside from hyphens). Each word of the parsed result will be displayed below along with the word count.

Secondary

The specific word input box will accept any specific word to count in the words to count input box. Instead of displaying the total word count, the count of the specific word will be displayed. The displayed parsed result will still show all of the words in the sentence, however, every occurrence of the specific word will be underlined.

Lesson Outline

  1. Students will need to implement the code from the original JavaScript version of the lesson.
  2. Convert all JavaScript files to TypeScript and type annotate the existing code.
  3. Step by step, implement a version of the preprocessor functionality in an object-oriented style with classes to demostrate the use of TypeScript class annotations.

About

A simple word count application to introduce students to TypeScript 🔡

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published