##A Javascript framework with implementation of major computer science algorithms and data structures
Let's make a new javascript framework to implement all the major computer science algorithms and data structures. During this implementation we want to learn the actual algorithms and a way to build javascript framework. The implementation span in following phases:
- Core JS framework
- JS unit testing and TDD
- Visualisation framework in JS
- Web App using the core and visualisation frameworks alongwith some other technologies for server side coding.
While building the framework we will cover the following topics:
- Javascript TDD using npm, gulp, karma and Jasmine
- JavaScript web frameworks learning
- Saucelab integration for multiple browser testing
- JsHint for quality checks
- Benchmark algorithms
- Library architectures
- Functional programming
- Selectors
- Events
- Ajax
- Animation
- Module loading
- Plugin architecture
- Browser capability detection
- Clean, reusable API design
- Benchmarking and performance
- Writing minifier-friendly JavaScript
##Part I
- Coding guidelines
- Minimal framework structure
- TDD for javascript
- Travis-CI integration
##Part II
- Saucelab integration
- JsHint for quality
- Start adding algorithms
Coding guidelines
The coding guidelines and the practices to develop this framework:
- Verbose: Variable and method names should be verbose so things are easy to find and understand
- Portable: Browsers and console should be catered for
- Explicit: Code should be quick to understand
- Comments: Let’s keep comment noise down. Comments should be succinct. TODO and FIXME are acceptable.
- Simple: Keep code simple. Let’s not bore readers!
- Indentation: Two spaces
- Semicolons: People might want to minify this library — let’s keep simicolons!
- Quality: JsLint and reader comments!
- Testing: Test first development for both browsers and console
- Versioning: GitHub to the rescue
JSHint
- Before committing please run
gulp lint
for javascript precompile linting. - We are using
.jshintrc
for all jshint configurations. - Please follow jshint options for documentation and configurations.
Saucelab Integration
- Need to have a saucelab account and create a sauce.json file having username & password in the root directory of the project.
- Format of sauce.json
{
"username": "saucelab_username",
"accessKey": "saucelab_key"
}
- Command to trigger our build in saucelab cloud infrastructure
gulp ci
##Part III
- Enhancing core JS framework structure
- Benchmarking algorithms
##Part IV
- Add algorithms
- Enhancing core JS framework structure
- Benchmarking algorithms
- Distribution
- Algorithms analysis
##Authors
- Manohar Negi
- Samar Panda