IndyWatch Education Feed Archiver

Go Back:30 Days | 7 Days | 2 Days | 1 Day

IndyWatch Education Feed Today.

Go Forward:1 Day | 2 Days | 7 Days | 30 Days

IndyWatch Education Feed was generated at Community Resources IndyWatch.

Saturday, 19 May


How to build an app with ARKit and Unity featuring Harry Potter PortKey freeCodeCamp - Medium

Augmented Reality. The future screams of it. The present is full of it: filters, games, and AR apps are popping up daily. Imagine a world where everywhere you look there are visual data aids to augment your comprehension.

Now, I would rather go all in on VR, especially after seeing Ready Player One. Oh how I wish I could be transported to Oasis right now! However, AR has more real world use cases from furniture shopping to building industrial factoriesthe possibilities are endless.

Augmented reality will be an essential part of your daily life. It will change everything. Tim Cook

Now, these claims have to hold the test of time (powerful use cases, realistic visuals, processing speed of hardware, and so on). Until then, Mobile AR is possibly the test bed for developers, before a headset or something similar is part of your everyday tech, along with a community of AR developers and a bevy apps.

Image source

What is a Portkey?

(For muggles, here is the definition *wink wink*):

A Portkey, in Harry Potter world, is an enchanted object which, when touched, will instantly transport a person from point A to point B. The object is usually a worthless piece of junk and is randomly placed around so as not to attract attention.

Project (around 3 hours)

In this tutorial, youll learn to build a Unity app with ARKit. Well add an augmented reality layer featuring Harry Potter PortKeys. Most of the time you spend will be on installations, so grab your coffee and get ready!

Step 1: Installation

You will also need a iOS developer account and iPhone, preferably, to take the AR app you build out for a spin.

Step 2: S...


Angular 6 and its new features explained in three minutes freeCodeCamp - Medium

ng add

ng add is a new command in Angular-cli that helps you install and download new packages in your angular apps. It works the same as npm, but it doesnt replace it.

ng update

ng update is a new Angular-cli command too. Its used to update and upgrade your packages. Its really helpful, for example, when you want to upgrade from Angular 5 to Angular 6, or any other package in your Angular app.

Declaring the providers inside the service itself

Before this update, you had to the declare the providers array in app.module.ts

Now with Angular 6, you can provide your service inside the supervisor itself by putting the providedIn:root property within the "@injectable" decorator.

Use ng-template instead of template directive

Angular elements

Angular 6 introduced us to Angular elements. Youre able to render your Angular elements as native web elements, and theyre interpreted as trusted HTML elements.

You can add Angular elements by running the command below:

Import createCustomElement in your component.

Then create your customized element!


The result:



Z-Index Explained: How to Stack Elements Using CSS freeCodeCamp - Medium

Photo by All Bong on Unsplash

I have always struggled with the CSS property z-index. It sounds so easy at first. Elements with a higher z-index value are displayed in front of those with a lower z-index value. Still, a lot of times I have ended up in situations where it seems like the z-index value didnt have any effect at all.

I decided that Id had enough of trial and error with z-index and that I wanted to get a better understanding. I hope this article can help you so you will never wonder why z-index is not doing what you expect it to do.

Default stacking order

Lets first mention the default order the browser stacks elements in, when no z-index is applied:

  1. Root element (the <html> element)
  2. Non-positioned elements in the order they are defined
  3. Positioned elements in the order they are defined

A non-positioned element is an element with the default position value static. A positioned element is an element with any other position value. Examples of other values are: absolute, relative, sticky or fixed.


<div class=pink>
<div class=orange></div>
<div class=blue></div>
<div class=green></div>


/* This is only the CSS that is relevant for the example. For the complete CSS check the links below the pictures. */
.blue, .pink, .orange {
position: absolute;

We defined the green box last in the document. Still, it appears behind the others because it is non-positioned.

Stacking with z-index

If we now want to change the stacking order of these elements, we can use the property z-index. An element with a higher z-index will be displayed in front of an element with a lower z-index. One thing to note is that z-index only works with positioned elements.

.blue, .pink, .orange {
position: absolute;
.blue {
z-index: 2;
.orange {
z-index: 3;
.green {
z-index: 100; // has no effect since the green box is non- positioned


How Apple Pay Works Under the Hood freeCodeCamp - Medium

Photo by Jonas Leupe on Unsplash

Do you use Apple Pay? Have you ever wondered how an Apple Pay transaction goes through? In this post, you will learn how Apple Pay works end to end.

Mobile payments have become very popular due to the convenience and the security they offer. No more plastic cards to carry around, and you do not have to worry about losing them (what a relief!).

In this article, I am going to discuss how Apple Pay works in general and how it works when it is used at a physical POS terminal, specifically. Ill briefly discuss the security benefits as well.

Before diving in, lets get familiar with some basic terminology.

Secure Element

A secure element (SE) is something that is mentioned when talking about Apple Pay, so we need to understand what it is.

According to Global Platform:

A Secure Element (SE) is a tamper-resistant platform (typically a one chip secure microcontroller) capable of securely hosting applications and their confidential and cryptographic data (e.g. key management) in accordance with the rules and security requirements set forth by a set of well-identified trusted authorities.

Apple Pay uses SE to store secret information associated with tokenized cards (we will talk about this later).

In the iPhones after iPhone 6, and in Apple Watch, an SE is embedded into the devices near-field communication (NFC) chip. This is used at payment terminals to perform transactions over NFC. SE emulates a payment card during an Apple Pay transaction.


Tokenization as a process is being adopted more and more in the payments industry. Here well try to understand the basics of Tokenization.

The following is a concise description from Wikipedia on Tokenization technology:

Tokenization, when applied to data security, is the process of substituting a sensitive data element with a non-sensitive equivalent, referred to as a token, that has no extrinsic or exploitable meaning or value. The token is a reference (i.e. identifier) that maps back to the sensitive data through a tokenization system. The mapping from original data to a token uses methods which render tokens infeasible to reverse in the absence of the tokenization system

In the context of credit cards and Apple Pay, tokenization is used to replace the Primary Account Number (PAN, or the credit card number) with a token. A token looks like a normal credit...


Beware of GraphQL Nested Mutations! freeCodeCamp - Medium

I have a cunning plan

Once upon a time, I hit upon the notion of organizing GraphQL mutations by nesting operations in a return type. The idea was that these operations would then mutate the parent entity.

The basic idea was this:

input AddBookInput {
ISBN: String!
title: String!
input RemoveBookInput {
bookId: Int!
input UpdateBookInput {
ISBN: String!
title: String!
type AuthorOps {
addBook(input: AddBookInput!): Int
removeBook(input: RemoveBookInput! ): Boolean
updateBook(input: UpdateBookInput!): Book
type Mutation {
Author(id: Int!): AuthorOps

And Ive used this technique a few times without ill effect, but Ive been lucky. Wheres the problem?

A reader pointed me to an issue on the GraphQL GitHub site where it was stated that the execution order of nested mutations is not guaranteed. Uh-oh. In the above case, I definitely want the addBook() mutation to occur before attempting an updateBook() operation on the same book. Alas, only so-called root mutations are guaranteed to execute in order.

An illustration of the problem

Say I have a message queue where I want the messages stored in the order in which they were received. Some messages take longer to process, so I use a mutation to guarantee that messages are processed sequentially:

type Query {
noop: String!
type Mutation {
message(id: ID!, wait: Int!): String!

The resolver logs when the message arrives, then waits a given time before returning the mutation result:

const msg = (id, wait) => new Promise(resolve => {
setTimeout(() => {
console.log({id, wait})
let message = `response to message ${id}, wait is ${wait} seconds`;
}, wait)
const resolvers = {
Mutation: {
message: (_, {id, wait}) => msg(id, wait),

Now for the trial run. I will want to ensure that the console log messages are in the same order as the mutation requests. Heres the request:

mutation root {
message1: message(id: 1, wait: 3000)
message2: message(id: 2, wait: 1000)
message3: message(id: 3, wait: 500)
message4: message(id: 4, wait: 100)

The response is:

"data": {


How to use a concurrent task queue in your Redux-Sagas freeCodeCamp - Medium

In this guide, you will learn what a concurrent task queue is, some of the best use cases, and how to write one.

The queue is one of the most used data structures. You probably use it every day when you shop for groceries (even online) or when you send a text message to your friends.

The concurrent task queue is a very powerful pattern that can really help you handle tasks over time or improve your performance.

TL;DR at the bottom

Lets start with the basics

What is a Queue? 

A queue is a linear structure in which values are added at one end and removed from the other. This discipline gives rise to a first-in/first-out behavior (FIFO) that is the defining feature of queues. The two fundamental queue operations are enqueue (add to back) and dequeue (remove from the front) (source).

Representation of a FIFO (first in, first out) queue (wikipedia)

Ok, when should we use it?

Use a queue when you need to maintain the order of events and process the value by that order.

Great, you convinced me! But why do I need the concurrency thing?

As I mentioned above, a queue is able to process one value at a time. But sometimes its not fast enough.

Consider the following case :

You are at your favorite grocery store and have just arrived at the cashier, but unfortunately there are many people waiting. To speed up the process, the store opened several more registers and each additional cashier has their own queue. So you just have to choose one. If one of the cashiers is having a technical problem or theyre just slow, that queue will be delayed even if the other slots are free.


Concurrent task queue to the rescue! 

We will use only one queue for our purposes. In that way, every time a slot becomes free, we will dequeue a person from the queue and send him to the free slot.

single concurrent queue (@andreagiuliaderba)


Now lets examine a use case

Last week I was working on a Google Chrome extension that sniffs and downloads HLS...


Math Debate: Adding Fractions Denise Gaskins' Let's Play Math

Cover image by Thor/ geishaboy500 via Flickr (CC BY 2.0)

Ive been working on my next Playful Math Singles book, based on the popular Things to Do with a Hundred Chart post.

My hundred chart list began many years ago as seven ideas for playing with numbers. Over the years, it grew to its current 30+ activities.

Now, in preparing the new book, my list has become a monster. Ive collected almost 70 ways to play with numbers, shapes, and logic from preschool to middle school. Just yesterday I added activities for fraction and decimal multiplication, and also tips for naming complex fractions. Wow!

Gonna have to edit that cover file

In the Advanced Patterns chapter, I have a section on math debates. The point of a math debate isnt that one answer is right while the other is wrong. You can choose either side of the question the important thing is how well you support your argument.

Heres activity #69 in the current book draft.

Have a Math Debate: Adding Fractions

When you add fractions, you face a problem that most people never think of. Namely, you have to decide exactly what you are talking about.

For instance, what is one-tenth plus one-tenth?



[BONUS] Drive Journal New Orleans To Pittsburgh, Hour 25 School Sucks Project

Drive Journal - A trip recap, in a state of delirium. With fellow travelers Andrew and Larry. How NOLA is both amazing and gross - and some thoughts about the event. Here's a link to the audio version: New Orleans To Pittsburgh Hour 25 Related PostsShit Has Gone Too Far (Bonus Content Preview)87Tags: bonus, a/vPre-Show ...

The post [BONUS] Drive Journal New Orleans To Pittsburgh, Hour 25 appeared first on School Sucks Project.


Become an Innovator with OMIE Coursera Blog

HEC Paris Masters in Innovation and Entrepreneurship (OMIE) is a self-paced 100% online degree that helps bring your ideas to life through a rigorous combination of academic theory and learning-by-doing activities.

We spoke with two participants from the program about why they chose OMIE and what its like to be part of a global classroom on Coursera.


Rahima is a project manager at General Electric, and her job requires her to be extremely organized and detail-oriented. She was looking for a master program that would help her become a more innovative business leader and decided that OMIE would be the perfect fit.

I came to a point in my career where I needed to discover a new way of thinking. I wanted to unleash my potential and develop a more creative mindset. I decided to apply when I realized I wanted to make real change within my organization. Rahima

Tim is a site manager for Colorite Compounds, a leading producer of polymers for medical and industrial use. Hes a self-starter whos founded 5 companies during his career, but he felt he needed to learn more entrepreneurial skills that the OMIE provides.

I wanted to get my Masters in Innovation and Entrepreneurship to help me accomplish my goals, and this program helps you draw a roadmap to success. I looked at a number of other universities, but I decided that didnt want a standard business degree. Instead, I wanted something focused on innovation. I believe anyone who graduates from this program will become more innovative and might even create the next big startup. Tim

Take part in a global classroom and engage with peers from all over the world without leaving your city.

The program is very diverse, and there are students from more than 22 different countries. There is a tremendous sense of community and you definitely feel supported by your fellow classmates. Even though youre not physically in the same classroom, theres a sense of camaraderie. Tim...


LIVE In New Orleans With Thad and Brett [PODCAST #564] School Sucks Project

The tense and truculent final event of Renegade University and School Sucks Project Present A Weekend With Thaddeus Russell. Attendees grab the mic and question us on the following topics: Jason - Foreign policy and the military: how to close the physical and psychological distance between America and its enemies? Norm - Higher education: how ...

Friday, 18 May


What future in mind? Critical Perspectives on Youth Wellbeing and Mental Health IN DEFENCE OF YOUTH WORK

Im not sure if any of our London folk are going to this conference, which is being held today, but it would be excellent to get feedback. The questions being raised need answering by all those wedded seemingly uncritically to notions of wellbeing and the rise of a mentally unhealthy younger generation. Somewhere, gathering dust, Ive got the notes of contribution I made to a conference on wellbeing. I should blow off the cobwebs and post it sometime.


What future in mind? Critical Perspectives on Youth Wellbeing and Mental Health.

DATE AND TIME: Fri 18 May 2018 from 10:00 to 16:00 

LOCATION: 152-153 Cayley Room, University of Westminster, 309 Regent Street, London, W1B 2HW
Amidst mounting concern over wellbeing and mental health, improving the state of mind of the young has become a preoccupation of Western economies. In the UK politicians, celebrities and even key members of the British monarchy have campaigned on the issue, demanding earlier intervention to support wellbeing, resilience and positive mental health in schools. More critical voices have drawn attention to the social and structural conditions shaping wellbeing, arguing that the problematization of personal development deflects from the politics of distress in a context of brutal austerity and rising...


How to write and deploy your first smart contract freeCodeCamp - Medium

Ever since Ethereum graced the crypto space with its presence in mid-2015, the revolutionary invention by Canadian-Russian Programmer Vitalik Buterin has given birth to many new decentralised applications (dApps). Along with the myriad of dApps being built, Ethereums success is mainly attributed to its implementation of smart contracts.

Interestingly enough, the invention of smart contracts dates back to 1996. Computer scientist Nick Szabo drew up the term smart contracts, and explains them as follows:

I call these new contracts smart, because they are far more functional than their inanimate paper-based ancestors. No use of artificial intelligence is implied. A smart contract is a set of promises, specified in digital form, including protocols within which the parties perform on these promises
Nick Szabo, 1996

His work later went on to inspire many other researchers and scientists, including Vitalik, who created Ethereum.

Basic info

Before we delve further into the guide, it is important to understand two important concepts.

The first thing that we need to understand is what the Ethereum Virtual Machine (EVM) is. Its sole purpose is to act as a runtime environment for smart contracts based on Ethereum. Think of it as a global super computer that runs all the smart contracts. As the name suggests, the EVM is virtual and not a physical machine. You can read more about the EVM here.

The second concept we need to understand is what is gas. In the EVM, gas is a unit of measurement used to assign a fee to each transaction with a smart contract. Each computation that happens in the EVM requires gas. The more complex and tedious it is, the more gas is needed to execute the smart contract.

Every transaction specifies the gas price it is willing to pay in ether for each unit of gas, allowing the market to decide the relationship between the price of ether and the cost of computing operations (as measured in gas). Its the combination of the two, total gas used multiplied by gas price paid, that results in the total fee paid by a transaction.

Fee for transaction = Total gas used * gas price;

Read more about gas here.

Now that you have basic knowledge about what a smart contract is and how the smart contract runs, we can go straight into how we are going to make our very own smart contract!

Setting up

Were going to use a tool...


React and Firebase are all you need to host your web apps freeCodeCamp - Medium

A lot of modern web development stories dont have good endings because of the complex number of technologies involved and the development approach adopted to get work done.

The real question is, how can we make this journey less painful, or should I say more fruitful and effective? Ideally the technologies we choose should be well-established and have great community support.

In this article, well look at two technologies that are very well established and have strong community support, that enable us to create live web apps more effectively.


  • You know some React, at least the basics
  • You have Node.js and NPM installed
  • You know how to use command line

So heres what were going to cover today:

  • Create a simple React application with create-react-app
  • Log into the Firebase Console and create a new project
  • Deploy it to Firebase Hosting with one simple command

When I initially tried deploying a React web application to Firebase hosting and wanted to get the web app up and running, I faced a few hurdles. I figured out that it may be useful to compile all of the research Ive carried out into a comprehensive article to help the community. So lets get started.

At a high level, this article is divided into three parts:

  1. Get a very basic React app in place
  2. Create a Firebase account
  3. Connect our Firebase console to our React app

Part 1 - create the React app

You likely know that create-react-app myapp is the best way to create a basic boilerplate for a React app. It not only creates a very basic boilerplate, but also adds the required dependencies needed for React to run.

If you dont realize the true magic and sheer power of this one line command, try creating a directory for React from scratch. Only then will you realize the true pain involved. A big shout out to those developers who got this command set up in the first place.

To get started, we need to get create-react-app installed on our machine.

$ npm install -g create-react-app

The -g flag in the command above installs the NPM package globally on the machine.

Once this is done, well use this package to get us a basic boilerplate for React.

$ create-react-app myapp

This will create a directory called myapp. Now we need to navigate into the directory and run the command below.

$ cd myapp
$ npm start

Once you run the command above, a local dev server should start and render the initial React app at the location localhost:3000

I hop...


How to deploy editable tables in HTML using Angular 5 and Entity Framework Core freeCodeCamp - Medium

Photo by Glenn Carstens-Peters on Unsplash


In this article, we are going to create a web application using ASP.NET Core 2.0 and Angular 5 with the help of the Entity Framework (EF) Core database-first approach. We will be creating a sample Employee Record Management system. To read the inputs from the user, we will use Angular forms with required field validations on the client side. We are also going to bind a dropdown list in the Angular form to a table in the database using EF Core.


  • Install .NET Core 2.0.0 or above SDK from here.
  • SQL Server 2008 or above.

Source Code

Before proceeding, I recommend you get the source code from Github.

Creating the tables

We will be using two tables to store our data.

  1. tblEmployee: used to store the details of employees. It contains fields such as EmployeeID, Name, City, Department, and Gender.
  2. tblCities: this contains the list of cities. It is used to populate the City field of the tblEmployee table. tblCities contains two fields, CityID and CityName.

Execute the following commands to create both tables

CREATE TABLE tblEmployee (  
Name varchar(20) NOT NULL ,
City varchar(20) NOT NULL ,
Department varchar(20) NOT NULL ,
Gender varchar(6) NOT NULL

CREATE TABLE tblCities (
CityName varchar(20) NOT NULL

Now we will put some data into the tblCities table. We will be using this table to bind a dropdown list in our web application. The desired city can be selected using this dropdown list. Use the following insert statements.

INSERT INTO tblCities VALUES('New Delhi');  
INSERT INTO tblCities VALUES('Mumbai');
INSERT INTO tblCities VALUES('Hyderabad');
INSERT INTO tblCities VALUES('Chennai');


Learn ReasonML by building Tic Tac Toe in React freeCodeCamp - Medium

You may have heard of Reason before. Its a syntax on top of OCaml that compiles to both readable JavaScript code and to native and bytecode as well.

This means you could potentially write a single application using Reason syntax, and be able to run it in the browser, and on Android and iOS phones as well.

This is one of the reasons why Reason (ouch, pun) is becoming increasingly popular. This is especially true in the JavaScript community because of the syntax similarities.

If you were a JavaScript developer before Reason came out and wanted to learn a functional programming (FP) language, you would have had to also learn a whole new syntax and set of rules. This mightve discouraged many people.

With Reason, you mainly need to understand the FP principles on which its basedsuch as immutability, currying, composition, and higher-order-functions.

Before I discovered Reason, I was trying to use FP principles in JavaScript as much as I could. However, JavaScript is limited in this sense, since its not meant to be an FP language. To take advantage of these principles effectively, you need to use a bunch of libraries that create complicated abstractions which are hidden from you.

Reason, on the other hand, opens the entire FP realm to all interested JavaScript developers. It provides us with an opportunity to use all those cool OCaml features using syntax we dearly know.

Last but not least, we can write our React or React Native apps using Reason.

Why should you give Reason a try?

I hope youll discover the answer for yourself by the time youve finished reading this post.

As we go through the source code of the classic Tic Tac Toe gamewritten in Reason, using ReactIll explain the core features of the language. Youll see the benefits of the strong type system, immutability, pattern matching, functional composition using pipe, and so on. Unlike JavaScript, these features are intrinsic to Reason itself.

Warming up

Before getting your hands dirty, you need to install Reason on your machine following this guide.

After that, you need to setup your app. To do this, you can either clone my repository containing the code of our app or you can setup your own project using ReasonScripts and code along.

To view your app in the browser, you need to compile your Reason files to JavaScript ones first. The...


How to create a progressive web app featuring Angular and headless CMS freeCodeCamp - Medium

Have you ever wondered how a headless Content Management System fits in with Progressive Web Apps?

I recently read my colleague Bryans story about Progressive Web Apps. The article talks about the implementation of a Progressive Web App (PWA) that lists interesting places stored in the headless CMS.

You could install this app on your device. It uses a service worker to cache the application and data about the points of interest. The application was written in plain JavaScript.

Having written a good share of JavaScript code, I wanted to expand on the concept using more complex frameworks.

I narrowed my choices down to three big playersReact, Vue, and Angular. I chose to use Angular, because it has already support for service workers, and I wanted to use TypeScript.

Each step of this tutorial will be accompanied by a link to a GitHub commit. This way, youll always be able to see what the code looks like.

To run the app, just download or clone the commit and run npm install and ng serve -o. The whole code is stored in one of the branches.

Lets get to it!


  • node.js v8+
  • Angular CLI v.1.7.4 installed as a global dependency via the npm package manager: npm install -g @angular/cli

Getting started

First of all, generate a new project. You can easily generate all boilerplate code using the awesome Angular CLI tools. Just navigate to a folder and generate a ready-to-run code:

ng new cloud-sample-angular-pwa-aps

Boilerplate configuration

Configured boilerplate commit

There are a few steps to configure the boilerplate.

The generated code uses plain CSS by default. But, you might want to make your life easier with SCSS. To achieve this, perform these steps:

  1. Set defaults.styleExt value from cssto scssin the/.angular-cli.jsonconfiguration file
  2. Rename styles.css to styles.scss
  3. Rename /src/app.component.css to /src/app.component.scssand reflect this renaming in app.component.ts in the component declaration atributes styleUrls property value.

Create some initial con...


How to manage more containers with Docker Swarm freeCodeCamp - Medium

Scaling beyond a single server is a an important feature to understand about containers. When you start using containers to make it easy to scale your application, things really start to get interesting. Imagine you have used Docker containers for development and testing. Now youre ready to go live.

How can you make sure your application has enough resources? If you go viral, how will you scale?

This is where you should start using a container orchestrator like Swarm. The same group that brought you Docker built Swarm. Swarm exists to manage Docker containers on a cluster of machines. Docker Swarm makes it easy to deploy, manage, and scale your containers.

In this article, we will walk though the basics of container orchestration on a cluster. We will discuss the features of Docker Swarm, including how to start a Swarm, deploy an application, and scale that application. If you are not familiar with Docker, take a look at my other articles.

What is Docker?
Starting your first container
Creating your first Dockerfile
Building your first image
Moving past one container

Make your way back here when you feel ready.

You may have heard me call Swarm a container orchestrator. What do I mean by that? Swarm takes control of managing and organizing both the hosts and Docker containers running on your cluster.

Think of Swarm as an application that understands how to run Docker commands. You tell it where all your Docker hosts are, what containers you want to run, and Swarm takes care of the rest. Swarm manages networking, access, the state of your containers, scaling services, load balancing, and even relocating containers if a host becomes unresponsive.

In this article, we are going to start up a Docker Swarm on your local machine. With our local Swarm we will familiarize ourselves with the most common commands and deploy some services.

Starting a swarm

To get started, you will need to have Docker-CE installed. To help you install Docker on your machine, please take a look at the Docker-CE site.

Once you have successfully installed Docker, starting up your first Docker Swarm is as easy as running one command. Open up your terminal...

IndyWatch Education Feed Archiver

Go Back:30 Days | 7 Days | 2 Days | 1 Day

IndyWatch Education Feed Today.

Go Forward:1 Day | 2 Days | 7 Days | 30 Days

IndyWatch Education Feed was generated at Community Resources IndyWatch.

Resource generated at IndyWatch using aliasfeed and rawdog