GithubHelp home page GithubHelp logo

hackhat / eike-test Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 840 KB

This is a project that will count the consonants and vowel in a certain text.

Home Page: https://rawgit.com/hackhat/eike-test/v0.0.2/dist/index.html

JavaScript 80.47% CSS 9.95% HTML 9.58%

eike-test's Introduction

Live example

This is a project that will count the consonants and vowel in a certain text. You just have to write some text in the top text input and your character statistics will be updated as you are typing in real time without any lag. Below the number of consonants will be displayed the top 3 consonants and how many times they appeared in the text. The same happens for the vowels.

Setup

Install: Clone and run npm install.

Dev mode: To run in dev mode run the command grunt serve (If no browser opens go to: http://localhost:8000/).

Tests: To run tests you need to run the command mocha (you have to install it previously globally).

Build: To build the application run the command grunt build and then check the ./dist) folder.

Process:

  • Generated project with webapp generator: In this way everything is already setup and I can focus on the task instead of the setup of the project.
  • Created tests;
  • Implemented the logic code;
  • Implemented the user interface;
  • Added compatibility with +IE8;

Programming assignment:

The goal is to allow the user to type in a text area and display the following information about the text that is typed:

  1. number of consonants that appear in the text
  2. number of vowels that appear in the text
  3. the top 3 consonants and top 3 vowels used and how many times they appear in the text.

This all has to update as the user is typing.

We'd like to see how you would handle this problem without using any MV* frameworks. jQuery or utility libraries are okay if you feel like you need any.

Things we would like to see:

Unit tests (testing framework of your choice, headless or in-browser doesn't matter)

The logic of the app has been tested here.

Efficient and fast. Typing shouldn't cause any freezing.

Yes, you can test it here. There was no need to use a webworker in this case (IE8 also doesn't support them).

Separation of concerns. The DOM updates should be handled separately from the other logic.

The logic of the app is in the TextAnalyzer.js class and the view part of the app is in the EikeApp module.

It should also work in IE8+ (we'll have to support IE8 for the near future unfortunately).

Yes, has been tested with browserstack (Win7 @ IE8), but you can also test it by opening this link on IE8 browser.

eike-test's People

Contributors

hackhat avatar totty90 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.