Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Front-End Code Quality, Part 1 [Video]

DZone's Guide to

Front-End Code Quality, Part 1 [Video]

In Part 1 of this series of video tutorials, we take a look at what the series hopes to accomplish, as well as a tutorial on using Jasmine for unit testing.

· Web Dev Zone ·
Free Resource

Learn how Crafter’s Git-based content management system is reinventing modern digital experiences. Download this white paper now. 

Introduction

Front-end development has become vital for many development projects, like SPAs(Single Page Applications), mobile development and Dynamics 365, so keeping and increasing code quality is very important. I have thus created some videos which walk you through how to improve code quality on the front-end.

Front-End Code Quality Introduction and Abstract

Introduction and overview of a series of videos about enhancing front-end development code quality, it includes understanding different types of JavaScript unit testing frameworks like Jasmine, Mocha, Jest, different types of task runner like Grunt and Gulp, different types of linting tools, like JSHint, ESLint, JSLint, CSSLint, different types of code formatter like Prettier and Tidy, how to write your first JavaScript test with Jasmine's standalone version, how to run JavaScript unit tests using Grunt, the command line, and PhantomJS, how to calculate code coverage for JavaScript unit tests using Istanbul,  how to run JavaScript unit tests using Visual Studio Test Explorer using the chutzpah extension, how lint JavaScript code using JSHint and how to run that from the command line using Grunt.Finally,I'll show how to integrate all the quality practices with Visual Studio Team Service build automation so it can be part of your CI/CD pipeline.

1- Writing Your First JavaScript Unit Test Using Jasmine's Standalone Version

In this video, we'll go over how to write your first JavaScript unit test using Jasmine as a BDD, or Behavior Driven Development, framework, how to use Jasmine's standalone version, how to reference the code under test, and how to change the configuration in specrunner.html file. You will learn how to use beforeEach to inject the needed elements of the DOM into the HTML and how to remove them using afterEach after having run the tests. This video is prerequisite for all the forthcoming videos if you don’t know Jasmine.

Crafter CMS is a modern Git-based platform for building innovative websites and content-rich digital experiences. Download this white paper now.

Topics:
web dev ,front-end development ,code quality ,unit testing

Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}