This file contains code snippets to be used while following the Angular 2 with Webpack Project Setup video tutorial.
You can find the full project in the angular2-course-webpack-starter repository.
<!DOCTYPE html>
| (() => { | |
| 'use strict'; | |
| /** | |
| * get unique contacts | |
| * @param {object} contacts | |
| * @return {Array.<Array.<string>>} | |
| */ | |
| const getUniqueContacts = (contacts) => { |
| #---------------GitHub Pages + Namecheap Domain + SSL Cheat Sheet------------# | |
| NOTE: You do NOT need to buy PositiveSSL from Namecheap. | |
| GitHub Pages provides free SSL automatically via Let's Encrypt. | |
| # Namecheap Domain Setup | |
| Buy Domain | |
| Go to namecheap.com, select and buy domain name. | |
| Navigate to DNS Settings | |
| Login to Namecheap → Username dropdown → Dashboard |
| // Trie.js - super simple JS implementation | |
| // https://en.wikipedia.org/wiki/Trie | |
| // ----------------------------------------- | |
| // we start with the TrieNode | |
| function TrieNode(key) { | |
| // the "key" value will be the character in sequence | |
| this.key = key; | |
This file contains code snippets to be used while following the Angular 2 with Webpack Project Setup video tutorial.
You can find the full project in the angular2-course-webpack-starter repository.
<!DOCTYPE html>
| <script>console.log({{ product | json }});</script> |
| var util = require('util'), | |
| events = require('events'); | |
| var colors = require('colors'); | |
| var testsResults = { | |
| passed:0, | |
| failed:0 | |
| } |
Below is the list of modern JS frameworks and almost frameworks – React, Vue, Angular, Ember and others.
All files were downloaded from https://cdnjs.com and named accordingly.
Output from ls command is stripped out (irrelevant stuff)
$ ls -lhS
566K Jan 4 22:03 angular2.min.js
| <?xml version="1.0" encoding="utf-8"?> | |
| <configuration> | |
| <appSettings> | |
| <!-- | |
| All appSettings are made available to your Node.js app via environment variables | |
| You can access them in your app through the process.env object. | |
| process.env.<key> | |
| --> |
| func checkShouldDownloadFileAtLocation(urlString:String, completion:((shouldDownload:Bool) -> ())?) { | |
| var request = NSMutableURLRequest(URL: NSURL(string: urlString)!) | |
| request.HTTPMethod = "HEAD" | |
| var session = NSURLSession.sharedSession() | |
| var err: NSError? | |
| var task = session.dataTaskWithRequest(request, completionHandler: { [weak self] data, response, error -> Void in | |
| if let strongSelf = self { | |
| var isModified = false |
I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!
\