Tuesday , 16 January 2018
Home / Tag Archives: arrays

Tag Archives: arrays

Selectors API – Advanced JavaScript Tutorial

Selectors API

The selectors API is a simpler way to grab elements by using CSS queries. If you recall, you can change the styles of an element using CSS. Here’s an example of how you would do so. [crayon-5a5ddcdb85030915886901/] To grab an element in general, you just type in the tag name. To grab an element with an ID, you type a …

Read More »

Nesting Objects and Arrays – JSON Tutorial

Nesting objects and arrays

Let’s talk about nesting JSON data. We’ll learn about nesting objects and arrays. Let’s update our script to this. [crayon-5a5ddcdb87e89014519089/] Inside our JSON object, we store 2 other JSON objects. Since we do it this way, we now have access to the other JSON objects. This makes it easier to manage and store data. Let’s learn how to access the …

Read More »

Creating JSON Data – JSON Tutorial

Creating JSON Data

So, let’s get started with creating JSON data. Before we do, let’s set up our files and folders. Create a file called index.html and a folder called js. Inside your js folder, create a file called script.js. Inside your index.html add this bit of code. [crayon-5a5ddcdb88f67468858064/] Nothing special going on here besides including our script. So, let’s get started! Open …

Read More »

For In Loop – JavaScript Tutorial

For In Loop

The for in loop in JavaScript is a special kind of loop. It’s specifically designed for arrays and objects. It allows you to loop through an array or object’s elements or properties. Let’s take a look at how to do this. Clear your script and add this bit of code. [crayon-5a5ddcdb8ab1e904936891/] You create an array. Next, we create our for …

Read More »

Multidimensional Arrays – JavaScript Tutorial

Multidimensional Arrays

When you hear the word multidimensional you think of space and time. In programming, it’s far more simpler than that. Multidimensional arrays are just arrays within arrays. Yes, it’s possible! Don’t worry, this tutorial doesn’t have any surprised ;). Let’s clear your script and add this bit of code into it. [crayon-5a5ddcdb8b1e7420823417/] I create a variable named people and insert …

Read More »

Manipulating Arrays – JavaScript Tutorial

Manipulating Arrays

Let’s talk about manipulating arrays now. There are a ton of methods for manipulating arrays, but we’ll talk about the mostly used ones. Before I move on, let me give you the technical terms for an array. The position or spot of an array is considered the index. The values in an array are items or elements. That’s all you’ll …

Read More »

Arrays – JavaScript Tutorial

Arrays

Arrays are a special kind of object. They can store multiple values. Let’s say you had a list of 800 names. If you had to create a variable for each of these names, then that would take a long time. Also, what if you were expecting to update this list with more or remove names? You’d have to manually create …

Read More »
ULTIMATE NODE JS WITH SQL COURSE
Want to learn how to create web applications with Node.js and SQL? Check out my course!
Get 93% off my course. You'll also learn how to build real world applications using Node and SQL. This is a limited time offer
Yes, I would like to get 93% off your course!
No Thanks!
close-link