{"id":24,"date":"2020-01-19T06:00:00","date_gmt":"2020-01-19T06:00:00","guid":{"rendered":""},"modified":"2023-08-20T01:27:42","modified_gmt":"2023-08-20T01:27:42","slug":"javascript-informational-best-of-the-basics","status":"publish","type":"post","link":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/","title":{"rendered":"JavaScript Informational: Best of the Basics"},"content":{"rendered":"<div>\n<h1>\nBest of the Basics: JavaScript Informational<\/h1>\n<div>\n<img decoding=\"async\" alt=\"JavaScript Informational: Image by: Keith D Commiskey | https:\/\/keithdc.com @2020\" class=\"article-base ref-link-open-00\" src=\"https:\/\/kdcinfo.com\/app\/info-js\/info-js-600-198.png\" title=\"JavaScript Informational: Image by: Keith D Commiskey | https:\/\/keithdc.com @2020\" \/><\/div>\n<div>\nJavaScript Informational: Best of the Basics: A full run through for entry- and mid-level developers looking for some solid fundamentals. Comments and suggestions always welcome.<\/div>\n<div>\nFor those new to the language, this is my own personal introduction to the topic garnered from over 17 years of experience: I&#8217;m throwing it out into the informational nexus. <span>-Keith D Commiskey<\/span><\/div>\n<p><em>So you wanna control your browser, ehhh&#8230;?<\/em><\/p>\n<p><\/p>\n<h2>\nStart with a Solid Base<\/h2>\n<div>\n<span>Variables<\/span> are the crux of most programming languages, and a good place to start. You have to be able to ask for, handle, save, and recall various tidbits of information.<\/div>\n<ul>\n<li><span>Q:<\/span> Why would you want to create a variable?<\/li>\n<li style=\"height: 5px; line-height: 0; list-style-type: none;\">&nbsp;<\/li>\n<li><span>A:<\/span> Variables are a part of what allows us to control \u201capp\u201dlications\u2014such as your web browser.<\/li>\n<\/ul>\n<div>\nEveryone reading this informational on a web browser has the ability to <b>create a variable in less than 30 seconds.<\/b><br \/>\n        For instance, most browsers allow you to open their \u201cdeveloper tools\u201d using the F12 key.<br \/>\n        If you click the \u201cConsole\u201d tab at the top of those tools, and type the following at the &gt; prompt:<br \/>\n        <span>var <span>myvar<\/span> = \u201chello\u201d;<\/span> and press enter.\n    <\/div>\n<div>\nCongratulations!<\/div>\n<div>\nHere, <span>myvar<\/span> is the <i>name<\/i> of your variable (<span>var<\/span> is you telling the computer that you are about to create a variable).<br \/>\n        <b>Once you assign information to a variable, you can then access that information<\/b>\u2014by referring to your variable&#8217;s name\u2014<b>with other code.<\/b><br \/>\n        For instance, you can assign numbers to two different variable names, and then add those two variables together.<br \/>\n        In doing that, you will have basically just created the &#8216;addition&#8217; function on a calculator. Bet you didn&#8217;t know you&#8217;d be doing that today.\n    <\/div>\n<ul>\n<li><span>Q:<\/span> <i>What kind<\/i> of information can you put in a variable?<\/li>\n<li style=\"height: 5px; line-height: 0; list-style-type: none;\">&nbsp;<\/li>\n<li><span>A:<\/span><br \/>\n            These are called <u>data types<\/u>, and they refer to things like <span>string<\/span>s and <span>number<\/span>s.<br \/>\n            Previously you added a <span>string<\/span>, <b>\u201c<span>hello<\/span>\u201d<\/b>.<br \/>\n            Then just now you mentally added a <span>number<\/span>, which you could do by typing <span>var myvar = 34;<\/span> and pressing enter.\n        <\/li>\n<\/ul>\n<div>\nYou can check what data type a variable is holding by using: <span>typeof myvar;<\/span> which will return either \u201c<span>string<\/span>\u201d or \u201c<span>number<\/span>\u201d (or a few others).\n    <\/div>\n<div>\nIn JavaScript, just like <span>string<\/span> and <span>number<\/span>, there are <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/JavaScript\/Data_structures\" target=\"kdcNewWinExt\" rel=\"noopener\">seven of these data types<\/a>, and they&#8217;re referred to as \u201c<b>primitive data types<\/b>\u201d<br \/>\n        which just means the base objects themselves cannot be altered (for instance, the <span>number<\/span> 3 will always be the <span>number<\/span> 3,<br \/>\n        although your <span>myvar<\/span> reference to the <span>number<\/span> 3 may change).\n    <\/div>\n<div>\nAlongside these seven primitive data types, there is the <b>\u201c<span>object<\/span>\u201d data type<\/b>, which is the primary way that we\u2014as developers\u2014work with data.<br \/>\n        These objects can also be based on the seven primitive data types, and as a reference (variable assignment) to those primitive data types, their values <i>can be changed<\/i>.\n    <\/div>\n<div>\n<h2 align=\"center\">\nAn Important Note<\/h2>\n<div align=\"center\">\nWhen assigning a type of data to a variable\u2014be it a <span>string<\/span>, <span>number<\/span>,<br \/>\n                or other\u2014<b>it should never be changed to a different data type<\/b>.<br \/>\n                If you initially assign <span>var myvar = 3;<\/span> you should<br \/>\n                not try to set it later in the code to be <span>myvar = \u201c3\u201d;<\/span><br \/>\n                (which is a <span>string<\/span>\u2014not a <span>number<\/span>).\n        <\/div>\n<\/div>\n<h3>\nThe Base<\/h3>\n<ul>\n<li>Data is one of the underlying fundamentals consistent across every application.<\/li>\n<li>Variables allow us to handle that data.<\/li>\n<li>Data Types allow us to keep things organized.<\/li>\n<\/ul>\n<h2>\nIt&#8217;s All About the Data<\/h2>\n<h3>\nUnderstanding Data Types<\/h3>\n<div>\n<b>The basis for most things you do with data in JavaScript.<\/b><\/div>\n<div>\n<span>typeof<\/span> =&gt; <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/JavaScript\/Data_structures\">Data Types<\/a> =&gt; The types of data that are stored in variables.\n    <\/div>\n<div>\nAs your program grows, it will grow harder to keep track of all your variables.<br \/>\n        When you get code from other developers, it will grow harder to keep track of all your variables.<br \/>\n        With every new feature you add to your web app, it will grow harder to keep track of all your variables.\n    <\/div>\n<ul>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n            <b>To keep track of your variables, you need to be able to check them.<\/b>\n        <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n            You&#8217;ll need to see what type of data is in them (if any), or if they even exist (i.e. <i>if they&#8217;ve been created<\/i>).\n        <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n            Checking data types helps us control the flow of our data.\n        <\/li>\n<\/ul>\n<div>\n<u>Important Note:<\/u> There are two ways a variable comes into being, and we can check for those states.<br \/>\n        If the variable hasn&#8217;t been created and doesn&#8217;t exist at all, it is undeclared (and <b>will throw a Reference error<\/b> in the browser).<br \/>\n        If the variable has been created but hasn&#8217;t been assigned anything, it is <span>undefined<\/span> (which you can\u2014and will\u2014check for regularly).\n    <\/div>\n<ul>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n            <b>Declared:<\/b> <span>var myVar;<\/span> \/\/ But <b>&#8216;NOT defined&#8217;<\/b>.\n        <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n            <b>Defined:<\/b> <span>myVar = &#8221;;<\/span> \/\/ The <span>=<\/span> assignment operator will assign a value and define the variable.\n        <\/li>\n<\/ul>\n<div style=\"margin: 2rem auto; padding: 1.5rem 2rem;\">\n<i><b>This really is important stuff,<\/b> I promise!<\/i> If you&#8217;re bored &#8230; it will pass (or try accounting <i>(j\/k!!)<\/i>). This really is just the basics. You can&#8217;t build the house until you learn to swing the hammer (and other cool sayings&#8230;) <span> \ud83d\ude42 <\/span>\n    <\/div>\n<h2>\nAnd without further ado&#8230;<\/h2>\n<h3>\nIntroducing&#8230; <b><i>Your<\/i> Data Types!<\/b><\/h3>\n<div>\nThe <span>typeof<\/span> operator (or, &#8220;command&#8221;) will return <b>lowercase strings<\/b> for each of the data types listed below.<br \/>\n        As <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/JavaScript\/Reference\/Operators\/typeof#Description\" target=\"kdcNewWinExt\" rel=\"noopener\">noted on MDN<\/a>,<br \/>\n        these <span>typeof<\/span> return strings can be one of the following:\n    <\/div>\n<table>\n<thead>\n<tr>\n<th><span>typeof<\/span><\/th>\n<th>Result<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>String<\/td>\n<td>&#8220;<span data-type=\"\">string<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>Number<\/td>\n<td>&#8220;<span data-type=\"\">number<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>Boolean<\/td>\n<td>&#8220;<span data-type=\"\">boolean<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>Undefined<\/td>\n<td>&#8220;<span data-type=\"\">undefined<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>Null<\/td>\n<td>&#8220;<span data-type=\"\">object<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>Function object<\/td>\n<td>&#8220;<span data-type=\"\">function<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>Symbol (new in ECMAScript 2015)<\/td>\n<td>&#8220;<span data-type=\"\">symbol<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>BigInt (new in ECMAScript 2020)<\/td>\n<td>&#8220;<span data-type=\"\">bigint<\/span>&#8220;<\/td>\n<\/tr>\n<tr>\n<td>Any other object<\/td>\n<td>&#8220;<span data-type=\"\">object<\/span>&#8220;<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>\nSome Clarity<\/h3>\n<table>\n<tbody>\n<tr>\n<td colspan=\"3\"><span>Number<\/span>, <span>String<\/span>, <span>Boolean<\/span>, <span>Object<\/span>\n            <\/td>\n<\/tr>\n<tr>\n<td style=\"width: 100px;\"><\/td>\n<td colspan=\"2\">\n<ul style=\"margin: 0; padding: 0;\">\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        <span>var = \u201cstring\u201d; \/\/ <span>3, \u201c3\u201d, true|false, {}<\/span><\/span>\n                    <\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 100px;\"><\/td>\n<td style=\"width: 100px;\"><\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td colspan=\"3\" style=\"padding-top: 2rem;\"><span>Undefined<\/span><\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td colspan=\"2\">\n<ul style=\"margin: 0; padding: 0;\">\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        The check for `<span>undefined<\/span>` will check both the &#8216;undeclared&#8217; and &#8216;undefined&#8217; states (these two states were noted earlier).\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        The `<span>(typeof yourReference !== &#8216;undefined&#8217;)<\/span>` condition is used quite a bit.\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        <u>Note<\/u>: `<span>typeof<\/span>` returns a lowercase &#8216;<span>string<\/span>&#8216; ^^^ for comparison.\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">Example:\n<div>\n<span>if (typeof myVar !== &#8216;undefined&#8217;) {<\/span><br \/>\n<span>   console.log(&#8216;Nice! Variable is set.&#8217;);<\/span><br \/>\n<span>}<\/span>\n                        <\/div>\n<\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 100px;\"><\/td>\n<td style=\"width: 100px;\"><\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td colspan=\"3\" style=\"padding-top: 2rem;\"><span>Null<\/span><\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td colspan=\"2\">\n<ul style=\"margin: 0; padding: 0;\">\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        Value of <span>var<\/span> set to <i>nothingness<\/i> (some methods return <span>null<\/span>).\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        To check for <span>null<\/span>, instead of <span>typeof<\/span>, use <span>if (<b>myVar === null<\/b>) { &#8230; }<\/span>.\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        Due to legacy reasons, <span>typeof null === &#8220;object&#8221;<\/span>.\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        Remember, <span>null<\/span> is not the same as <span>undefined<\/span> or empty (\u201c\u201d).\n                    <\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 100px;\"><\/td>\n<td style=\"width: 100px;\"><\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td colspan=\"3\" style=\"padding-top: 2rem;\"><span>Symbol<\/span>, <span>BigInt<\/span><\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td colspan=\"2\">\n<ul style=\"margin: 0; padding: 0;\">\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        Advanced topics; Relatively new to JavaScript.\n                    <\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<tr>\n<td style=\"width: 100px;\"><\/td>\n<td style=\"width: 100px;\"><\/td>\n<td><\/td>\n<\/tr>\n<tr>\n<td colspan=\"3\">\n<h3>\nDon&#8217;t change data types !!!<\/h3>\n<\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td colspan=\"2\">\n<ul style=\"margin: 0; padding: 0;\">\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        In other words, <i>don&#8217;t change a variable&#8217;s data type<\/i> <b>by placing <u>a new type of value<\/u> in the variable<\/b>.\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        If a variable is a &#8220;string&#8221;, it <b>should always be a string!<\/b>\n                    <\/li>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n                        Coding Examples:<\/p>\n<ul style=\"list-style-type: none; margin: 0; padding: 0;\">\n<li style=\"margin: 0; padding: 1rem 0;\">\n<div>\n\/\/ This will work (in JavaScript), but is considered poor practice.<br \/>\n<span>var myNumber = &#8220;3&#8221;;<\/span> \/\/ Should instead set to just the Number 3<br \/>\n<span>myNumber = 4;<\/span>\n                                <\/div>\n<\/li>\n<li style=\"background-color: rgb(215 , 255 , 235); margin: 0; padding: 1rem 0;\">\n<div>\n<b>\/\/ Best practice!<\/b><br \/>\n<span>var myNumber = 3;<\/span> \/\/ Look ma&#8217;, no quotes!<br \/>\n<span>myNumber = 4;<\/span> \/\/ A &#8220;Number&#8221; is a type of object like &#8220;String&#8221;.\n                                <\/div>\n<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2>\nTo the Code!<\/h2>\n<h3>\nComparing &#8230; Stuff<\/h3>\n<div>\nComparators &lt; === &gt; simply compare two data items. For example, <span>3 == 3<\/span> compares two 3s.<\/div>\n<div>\nThe biggest thing here to learn and remember is that there are two ways to compare data items.<br \/>\n        <\/p>\n<ul style=\"max-width: 600px;\">\n<li style=\"margin: 1.5rem 0 0.5rem -1rem;\">\n                <b>Compare the Values<\/b> (between two variables) <span>==<\/span> and <span>!=<\/span><br \/>\n                Use 2 character signs to just compare the values.<br \/>\n                <span>3 == &#8216;3&#8217;<\/span> === true.\n            <\/li>\n<li style=\"margin: 2rem 0 0.5rem -1rem;\">\n                <b>Compare the Values <u>AND<\/u> the Data Types<\/b> <span>===<\/span> and <span>!==<\/span><br \/>\n                Use 3 character signs to compare the values <u>AND<\/u> the data types.<br \/>\n                <span>3 === &#8216;3&#8217;<\/span> === false because one is a <span>number<\/span> and one is a <span>string<\/span>.\n            <\/li>\n<li style=\"margin: 2rem 0 0.5rem -1rem;\">Best practice is to <span>always use <span>===<\/span><\/span> (especially being that variables should never change what &#8216;<span>type<\/span>&#8216; of values they hold).<\/li>\n<\/ul>\n<\/div>\n<table style=\"border-radius: 10px; border-spacing: 0.5rem; border: 1px dashed green; margin: 1rem 0 1rem 2rem; max-width: 600px; padding: 0.5rem; width: 80%;\">\n<tbody>\n<tr>\n<td>Common algebra comparison operators.<\/td>\n<td style=\"text-align: center; width: 10%;\"><span>&lt;<\/span>&nbsp;\n            <\/td>\n<td style=\"text-align: center; width: 10%;\"><span>&lt;=<\/span>&nbsp;\n            <\/td>\n<td style=\"width: 10%;\"><span>&gt;<\/span>&nbsp;\n            <\/td>\n<td style=\"width: 10%;\"><span>&gt;=<\/span>\n            <\/td>\n<\/tr>\n<tr>\n<td><span>Check for value only<\/span><\/td>\n<td style=\"text-align: center;\"><span>==<\/span>\n            <\/td>\n<td style=\"text-align: center;\"><span><b>!=<\/b><\/span>\n            <\/td>\n<td colspan=\"2\"><\/td>\n<\/tr>\n<tr>\n<td><span>Check value <b><u>and<\/u> data type<\/b><\/span><\/td>\n<td style=\"text-align: center;\"><span>===<\/span>\n            <\/td>\n<td style=\"text-align: center;\"><span><b>!==<\/b><\/span>\n            <\/td>\n<td colspan=\"2\"><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>\nCoding Styles; Standards vs. Preferences<\/h3>\n<div>\nAs you learn to code, you will quickly find there are many ways to do things. These &#8216;options&#8217; can at times lead to industry standards, while others lead more to personal preferences.<br \/>\n        Additionally, different industries may have different coding styles.\n    <\/div>\n<div style=\"margin: 2rem auto; padding: 1.5rem 2rem;\">\nBest practices can at times be subjective; choose your preference.<br \/>\n        But! <b>Be able to code in the style of the project you&#8217;re working in.<\/b>\n    <\/div>\n<h4>\nOptional: Curly Braces (grouping bits of code)<\/h4>\n<div>\nWhen using various features of JavaScript, many times you will be provided <b>an option<\/b> to wrap your code with<br \/>\n        <span style=\"background-color: yellow; color: red; padding: 0.25rem;\">{<\/span> curly braces <span style=\"background-color: yellow; color: red; padding: 0.25rem;\">}<\/span>.<br \/>\n        When you come across these <i>optional braces<\/i>&#8230; Best practice is to <span>&#8220;always&#8221; wrap your statements with curly braces<\/span>.\n    <\/div>\n<div>\nFor example, not using them for statements that only have one line (one &#8230; &#8220;event to run&#8221;) is optional.<br \/>\n        However, <span>consistency would dictate<\/span>\u2014because you have to use them when you have two or more lines of code to run\u2014<span>they should always be used.<\/span>\n    <\/div>\n<ul style=\"list-style-type: none;\">\n<li style=\"margin: 0; padding: 1rem 0 0;\">\n            Coding Examples:\n        <\/li>\n<li style=\"margin: 0; padding: 1rem 0;\">\n<div>\n\/\/ This will work, and some developers prefer this.<br \/>\n<span>if (alwaysWrapWithBraces === true) <span style=\"color: red; outline: 2px solid red; padding: 0.25rem;\">&nbsp;<\/span><\/span><br \/>\n<span>   console.log(&#8220;One-liners should be wrapped up for consistency.&#8221;);<\/span><br \/>\n<span><span style=\"color: red; outline: 2px solid red; padding: 0.25rem;\">&nbsp;<\/span><\/span>\n            <\/div>\n<\/li>\n<li style=\"background-color: rgb(215 , 255 , 235); margin: 0; padding: 1rem 0;\">\n<div>\n<b>\/\/ Best practice (subjective)<\/b><br \/>\n<span>if (alwaysWrapWithBraces === true) <span style=\"background-color: yellow; color: red; padding: 0.25rem;\">{<\/span><\/span><br \/>\n<span>   console.log(&#8220;Consistency is a valued trait in web development.&#8221;);<\/span><br \/>\n<span><span style=\"background-color: yellow; color: red; padding: 0.25rem;\">}<\/span><\/span>\n            <\/div>\n<\/li>\n<\/ul>\n<h4>\nOptional: Semicolons<\/h4>\n<div>\nSame holds true for <b>semicolons<\/b>at the end of a line<b>;<\/b><\/div>\n<div>\nThey are optional, but because there are some <a href=\"https:\/\/www.freecodecamp.org\/news\/codebyte-why-are-explicit-semicolons-important-in-javascript-49550bea0b82\/\" target=\"kdcNewWinExt\" rel=\"noopener\">gotchas<\/a> you have to watch out for,<br \/>\n        and for which <b>merely introduce more potential entry points for bugs<\/b>, as with the argument for curly braces, <b>it&#8217;s best to just always include them.<\/b><\/div>\n<h3>\nParentheses Matter!<\/h3>\n<div>\nIn programming, when you need a couple things to <b>happen at the same time<\/b>\u2014just like with algebra priorities of Addition, Subtration, Multiplication, etc. (PE(MD(AS)))\u2014<br \/>\n        there are times when you need to <b>tell the browser in which order things need to be done.<\/b>\n    <\/div>\n<div>\nSuch a time in development would be when performing actual math calculations, or sometimes when performing other operations as well.\n    <\/div>\n<div>\n<i>For these examples<\/i>, understand that <span>Math.random()<\/span><br \/>\n        <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/JavaScript\/Reference\/Global_Objects\/Math\/random\" target=\"kdcNewWinExt\" rel=\"noopener\">returns a floating-point, pseudo-random number in the range 0\u20131 (inclusive of 0, but not 1)<\/a>.<br \/>\n        Ergo,<\/p>\n<div>\n<span><span>Math.random()<\/span> &lt;= <b>0.999999999999999999<\/b><\/span> and<br \/>\n<span><span>Math.random()*2<\/span> &lt;= <b>1.9999999999999999<\/b><\/span>\n        <\/div>\n<table style=\"border-spacing: 0.5rem 0.2rem;\">\n<thead>\n<tr>\n<th>Parentheses Placement<\/th>\n<th>Possible<br \/>\nValues<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td><span>Math.floor(<\/span>Math.random() * 2 &#8211; 1<span>)<\/span><\/td>\n<td><b>\/\/ -1 \u2013 0<\/b><\/td>\n<\/tr>\n<tr>\n<td><span>Math.floor(<\/span>Math.random() * (2 &#8211; 1)<span>)<\/span><\/td>\n<td><b>\/\/ 1<\/b><\/td>\n<\/tr>\n<tr>\n<td><span>Math.floor(<\/span>Math.random() * (3 &#8211; 1)<span>)<\/span><\/td>\n<td><b>\/\/ 0 \u2013 1<\/b><\/td>\n<\/tr>\n<tr>\n<td><span>Math.floor(<\/span>Math.random() * (3 &#8211; 1) + 1<span>)<\/span><\/td>\n<td><b>\/\/ 1 \u2013 2<\/b><\/td>\n<\/tr>\n<tr>\n<td><span>Math.floor(<\/span>Math.random() * 3<span>)<\/span><\/td>\n<td><b>\/\/ 0 \u2013 2<\/b><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<div>\nYour best approach when coding things of this nature is to <b>know what your expected output should be.<\/b> Then you can <b>perform testing based on your expected output.<\/b>\n    <\/div>\n<div>\nFor breaking down more complex math problems, you can also try an online calculator such as the &#8220;Equation Calculator&#8221; I shared in <a href=\"https:\/\/kdcinfo.com\/blog\/2019\/10\/17\/solve-for-x-with-the-equation-calculator\/\" target=\"kdcNewWinInt\" rel=\"noopener\">Oct 2019, &#8220;Solve for &#8216;x&#8217; with the Equation Calculator&#8221;<\/a>.\n    <\/div>\n<h2>\nMiscellaneous Tidbits<\/h2>\n<div>\nAs you progress in your early learning, the following tidbits of advice should help advance your fundamental understanding of certain things that often go unsaid.<\/div>\n<h3>\nNaming Conventions<\/h3>\n<ul>\n<li style=\"margin: 0; padding: 0.5rem 0 0;\">\n            <span>HTML &lt;tags&gt;&lt;\/tags&gt;:<\/span> The general concensus is that <span>&lt;html&gt;<\/span> tags are &#8220;almost always&#8221; lowercase.<br \/>\n            However\u2014technically\u2014<b>it doesn&#8217;t matter.<\/b> <span>But!<\/span> I look at my code from 2005 and it&#8217;s &lt;YELLING AT ME&gt;!<br \/>\n            I&#8217;ve preferred lowercase ever since that JUMPED out at me one day.<br \/>\n            <span>&lt;!DOCTYPE html&gt;<\/span> is a good exception to this rule.\n        <\/li>\n<li style=\"margin: 0; padding: 1.5rem 0 0;\">\n            <span>HTML ID attributes<\/span> should simply avoid using <b>kebab-case<\/b>, and instead use either <b>camelCase<\/b> or <b>PascalCase<\/b>.<br \/>\n            After many years of seeing differently, this took some major thought adjustment, but my IDs from here-on-out will be <b>PascalCase<\/b> (aka, TitleCase).\n        <\/li>\n<li style=\"margin: 0; padding: 1.5rem 0 0;\">\n            <span>CSS <span>.class-names<\/span><\/span> should be written and named using <b>kebab-case<\/b> (all-lowercase-with-hyphens).\n        <\/li>\n<li style=\"margin: 0; padding: 1.5rem 0 0;\">\n            <span>JavaScript <span>variable<\/span> and <span>function<\/span> names<\/span> should be written and named using <b>camelCase<\/b> (not to be confused with <b>TitleCase<\/b> (or <b>PascalCase<\/b>)).\n        <\/li>\n<\/ul>\n<h3>\nComments are Public<\/h3>\n<div>\nHTML, CSS, and JavaScript code <b>comments can be seen by anyone<\/b> who can view your web page.<br \/>\n        Comments are hidden from the browser&#8217;s &#8220;viewing&#8221; page, but the comments are still accessible if you view the page source (Ctrl|Cmd-U) or explore in your browser&#8217;s Developer Tools.\n    <\/div>\n<div>\n<span>Do NOT put sensitive or similar information in comments.<\/span>\n        <\/div>\n<h3>\n&lt;u&gt;<\/h3>\n<div>\nThe <span>&lt;u&gt;<\/span> tag is fine to use in some cases;<br \/>\n        especially if the site&#8217;s <span style=\"border: 1px dashed purple;\">&lt;a&gt;<\/span> link styles are <span style=\"border: 1px dashed purple;\">emphasized<\/span> in some manner<br \/>\n        so as not be confused with the <u>standard &lt;u&gt; underline<\/u>.<br \/>\n        Understand the context in which you&#8217;re working in.<br \/>\n        Be aware of your development environment and a site&#8217;s own coding styles.\n    <\/div>\n<h3>\nCopy\/Paste<\/h3>\n<div>\nPasting into Notepad is a nice trick for removing certain hidden characters that hitch a ride when copying sections of data from the internet or various documents (especially with code).<br \/>\n        Unfortunately it will not &#8220;always&#8221; remove all hidden characters.<br \/>\n        If problems with a certain section of text in your code persists and is proving challenging,<br \/>\n        you can also try pasting into a Word Processor, most of which provide the option to &#8220;show hidden characters.&#8221;\n    <\/div>\n<div>\nA couple approaches I use when I paste things into anywhere\u2014and then begin experiencing issues\u2014 (indicating it was due to the paste):<br \/>\n        <\/p>\n<ol>\n<li>Delete a chunk of the pasted information, test to see if the issue is still there, then &#8216;undo&#8217; the delete. Repeat until the error goes away, and narrow it down.<\/li>\n<li>When you use you left-right arrow keys to scroll through text, you&#8217;ll see the cursor scroll happily along.<br \/>\n                Hidden characters, however, will cause the cursor to &#8216;skip a beat&#8217; as it &#8216;goes over&#8217; the hidden character.<br \/>\n                When you see this skip happen, you know there&#8217;s something in there, and you can trim it out.\n            <\/li>\n<\/ol>\n<\/div>\n<h3>\nBlock vs. Inline vs. Inline-Block Elements<\/h3>\n<div>\n<span>DIV<\/span>s and <span>SPAN<\/span>s<\/p>\n<h4>\nUnderstanding &#8220;block&#8221; vs. &#8220;inline&#8221; vs. &#8220;inline-block&#8221; elements is crucial to front-end web development.<\/h4>\n<p><a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/HTML\/Block-level_elements\" target=\"kdcNewWinExt\" rel=\"noopener\">MDN has already done an excellent job of explaining these concepts.<\/a>\n    <\/div>\n<div>\nSpending one to two days digging deep into these will allow you to better comprehend some even more powerful features<br \/>\n            such as <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/CSS\/Layout_mode\" target=\"kdcNewWinExt\" rel=\"noopener\">Layout mode<\/a>, Flexbox, and CSS Grid.\n        <\/div>\n<h3>\nPadding, Margin<\/h3>\n<div>\nIt is extremely crucial to learn these, and <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/CSS\/Containing_block\" target=\"kdcNewWinExt\" rel=\"noopener\">no one explains it like MDN!<\/a>\n    <\/div>\n<h3>\nBorder; Outline<\/h3>\n<div>\n<a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/CSS\/border\" target=\"kdcNewWinExt\" rel=\"noopener\">According to MDN<\/a>,<\/p>\n<p><\/p>\n<div>\nBorders and outlines are very similar. However, outlines differ from borders in the following ways:<br \/>\n            <\/p>\n<ul>\n<li>Outlines never take up space, as they are drawn outside of an element&#8217;s content.<\/li>\n<li>According to the spec, outlines don&#8217;t have to be rectangular, although they usually are.<\/li>\n<\/ul>\n<\/div>\n<\/div>\n<ul>\n<li style=\"margin-bottom: 1rem;\">A <span>`border: 5px solid red;`<\/span> will visibly move\/shift adjacent content.<\/li>\n<li>An <span>`outline: 5px solid red;`<\/span> is more of an overlay and will not affect the contents.<\/li>\n<\/ul>\n<h3>\nNew HTML Element Types: YMMV (your miles may vary)<\/h3>\n<div>\nCheck compatibility charts regularly for target audience browser support.<br \/>\n        The MDN docs should be required reading (or at least required skimming).<br \/>\n        <\/p>\n<ul>\n<li><a href=\"https:\/\/developer.mozilla.org\/en\/docs\/Web\/HTML\" target=\"kdcNewWinExt\" rel=\"noopener\">MDN HTML<\/a><\/li>\n<li><a href=\"https:\/\/developer.mozilla.org\/en\/docs\/Web\/CSS\" target=\"kdcNewWinExt\" rel=\"noopener\">MDN CSS<\/a><\/li>\n<li><a href=\"https:\/\/developer.mozilla.org\/en\/docs\/Web\/JavaScript\" target=\"kdcNewWinExt\" rel=\"noopener\">MDN JavaScript<\/a><\/li>\n<li><a href=\"https:\/\/caniuse.com\/\" target=\"kdcNewWinExt\" rel=\"noopener\">Can I use&#8230;<\/a><\/li>\n<\/ul>\n<p>Every feature has its own chart. MDN especially includes notes on limitations of use, and all the charts usually include mobile browser support.\n    <\/p><\/div>\n<div>\nAs you grow with JavaScript, MDN and StackOverflow will typically become your primary go-tos.<br \/>\n            Although MDN may appear to be more cryptic early on, you will become more comfortable with it as you progress.\n        <\/div>\n<h3>\nTools<\/h3>\n<ul>\n<li>HTML Validation | <a href=\"https:\/\/validator.w3.org\/\" target=\"kdcNewWinExt\" rel=\"noopener\">https:\/\/validator.w3.org<\/a><\/li>\n<li>CSS Validation | <a href=\"http:\/\/jigsaw.w3.org\/css-validator\/\" target=\"kdcNewWinExt\" rel=\"noopener\">http:\/\/jigsaw.w3.org\/css-validator\/<\/a><\/li>\n<\/ul>\n<h3>\nCheat Sheets<\/h3>\n<ul>\n<li>HTML5 cheat sheet | <a href=\"https:\/\/websitesetup.org\/html5-cheat-sheet\/\" target=\"kdcNewWinExt\" rel=\"noopener\">https:\/\/websitesetup.org\/html5-cheat-sheet\/<\/a><\/li>\n<li>Windows keyboard shortcuts | <a href=\"https:\/\/www.google.com\/search?q=windows+keystrokes\" target=\"kdcNewWinExt\" rel=\"noopener\">https:\/\/www.google.com\/search?q=windows+keystrokes<\/a><\/li>\n<\/ul>\n<h3>\nA few common locations for project files<\/h3>\n<table>\n<tbody>\n<tr>\n<td colspan=\"2\">Local:<\/td>\n<td style=\"border-bottom: 1px dotted maroon;\"><b>Location on Computer\/Drive<\/b><\/td>\n<\/tr>\n<tr>\n<td style=\"width: 100px;\"><\/td>\n<td style=\"width: 125px;\">Windows<\/td>\n<td>[Desktop, My Documents, etc.]<\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td>Mac<\/td>\n<td>[Desktop, Documents, etc.]<\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td>Linux<\/td>\n<td>[\/var\/www\/html\/]<\/td>\n<\/tr>\n<tr>\n<td colspan=\"3\">Remote:<\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td><a href=\"https:\/\/github.com\/\" target=\"kdcNewWinExt\" rel=\"noopener\">GitHub<\/a><\/td>\n<td style=\"border-top: 1px dotted maroon;\">Provides <u>free public repositories<\/u><\/td>\n<\/tr>\n<tr>\n<td colspan=\"2\"><\/td>\n<td>A &#8220;repository&#8221; is a virtual folder that stores your project&#8217;s files.<br \/>\n                    You can have multiple repositories; each with its own project files.\n                <\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td><a href=\"https:\/\/gist.github.com\/\" target=\"kdcNewWinExt\" rel=\"noopener\">GitHub Gists<\/a><\/td>\n<td style=\"border-top: 1px dotted maroon;\">More for <b>code snippets<\/b><\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td><a href=\"https:\/\/bitbucket.org\/\" target=\"kdcNewWinExt\" rel=\"noopener\">BitBucket<\/a><\/td>\n<td style=\"border-top: 1px dotted maroon;\">Like GitHub, but isntead of free public repositories, BitBucket provides <u>free private repositories<\/u><\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td><a href=\"https:\/\/codepen.com\/\" target=\"kdcNewWinExt\" rel=\"noopener\">CodePen<\/a><\/td>\n<td style=\"border-top: 1px dotted maroon;\">Free online text editor with live preview pane<\/td>\n<\/tr>\n<tr>\n<td><\/td>\n<td colspan=\"2\" style=\"border-top: 1px dotted maroon;\">Others&#8230;<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>\nThe #1 essential tip for progressing your skills<\/h3>\n<div>\n<span>Little, Tiny, Side Projects<\/span><\/div>\n<div style=\"margin: 2rem auto; padding: 1.5rem 2rem;\">\nFamiliarity through repetition is a big part of the initial learning curve.\n    <\/div>\n<div>\nMake yourself a list of &#8220;things&#8221; you can create&#8230; perhaps some that might benefit your own work or study habits.<br \/>\n        The more little projects you challenge yourself to do, the more &#8216;life training badges&#8217; you&#8217;ll garner.\n    <\/div>\n<div>\nIf you can build yourself any little &#8220;thing&#8221; that does something with HTML, CSS, and JavaScript, you&#8217;ll have created a miracle. Build on it from there.\n        <\/div>\n<h3>\nAcronysms<\/h3>\n<div>\nYou may come across the acronym <span>a11y<\/span>; which refers to the word &#8220;Accessibility,&#8221; which begins with an <span>A<\/span>, followed by 11 characters and ending in a &#8220;<span>y<\/span>.&#8221;\n    <\/div>\n<div>\nYou will also come across this with i18n for internationalization (coding for other languages).<\/div>\n<div>\nThese types of &#8220;acronysms&#8221; are explained here: <a href=\"https:\/\/en.wikipedia.org\/wiki\/Acronym\">https:\/\/en.wikipedia.org\/wiki\/Acronym#Other_conventions<\/a><\/div>\n<div>\nFYI: &#8220;acronysms&#8221; is a made-up word; although there are 17k Google results. I enjoy research. \ud83d\ude00<\/div>\n<h2>\nLearning Resources<\/h2>\n<div>\n<span>One of the best coding walkthrough and <span>challenge sites for learning.<\/span><\/span><br \/>\n        <\/p>\n<div>\n<b>f<\/b>ree <b>C<\/b>ode <b>C<\/b>amp.org<br \/>\n<a href=\"https:\/\/learn.freecodecamp.org\/javascript-algorithms-and-data-structures\/basic-javascript\">Good simple, progressive, code exercises<\/a>\n        <\/div>\n<\/div>\n<h3>\nAdditional Learning Resources.<\/h3>\n<div>\n<div>\nGood base for code style: <a href=\"http:\/\/www.w3schools.com\/js\/default.asp\">W3School JavaScript Tutorial<\/a><\/div>\n<div>\nDeeper base for code style: <a href=\"http:\/\/www.w3schools.com\/js\/js_conventions.asp\">W3School JavaScript Style Guide and Coding Conventions<\/a><\/div>\n<\/div>\n<h2>\nBrought to you by<\/h2>\n<div style=\"padding-bottom: 3rem;\">\n<br \/>\nKeith D Commiskey @ 2020-01-18<br \/>\nLifetime Web Developer<br \/>\n<a href=\"https:\/\/keithdc.com\/\" target=\"kdcNewWinInt\" rel=\"noopener\">https:\/\/keithdc.com\/<\/a>\n    <\/div>\n<p><\/p>\n<div style=\"background-color: white; border-radius: 5px; border: 1px solid blue; bottom: 0.5rem; margin: 0; padding: 0.75rem; right: 0.5rem;\" type=\"footer\">\n<a href=\"https:\/\/keithdc.com\/\" target=\"kdcNewWinInt\" rel=\"noopener\">2020-01-18<\/a> | <a href=\"https:\/\/keithdc.com\/\" target=\"kdcNewWinInt\" rel=\"noopener\">KeithDC<\/a>\n    <\/div>\n<\/div>\n<div>&#8212;<br \/>\nKeith D Commiskey<br \/>\nhttps:\/\/keithdc.com<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Best of the Basics: JavaScript Informational JavaScript Informational: Best of the Basics: A full run through for entry- and mid-level developers looking for some solid<\/p>\n","protected":false},"author":1,"featured_media":175,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13,26,30,27,28,29],"tags":[],"class_list":["post-24","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-javascript","category-javascript-basics","category-javascript-developer","category-javascript-fundamentals","category-javascript-learn","category-js"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.9 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>JavaScript Informational: Best of the Basics - App Development: Odds and Ends<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"JavaScript Informational: Best of the Basics - App Development: Odds and Ends\" \/>\n<meta property=\"og:description\" content=\"Best of the Basics: JavaScript Informational JavaScript Informational: Best of the Basics: A full run through for entry- and mid-level developers looking for some solid\" \/>\n<meta property=\"og:url\" content=\"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/\" \/>\n<meta property=\"og:site_name\" content=\"App Development: Odds and Ends\" \/>\n<meta property=\"article:published_time\" content=\"2020-01-19T06:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-08-20T01:27:42+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2020\/01\/info-js-600-198.png\" \/>\n\t<meta property=\"og:image:width\" content=\"600\" \/>\n\t<meta property=\"og:image:height\" content=\"198\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Keith D Commiskey\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Keith D Commiskey\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"13 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/\"},\"author\":{\"name\":\"Keith D Commiskey\",\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/#\\\/schema\\\/person\\\/87980b154db7bd0cd7c569ca09328bac\"},\"headline\":\"JavaScript Informational: Best of the Basics\",\"datePublished\":\"2020-01-19T06:00:00+00:00\",\"dateModified\":\"2023-08-20T01:27:42+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/\"},\"wordCount\":2698,\"commentCount\":2,\"publisher\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/#\\\/schema\\\/person\\\/87980b154db7bd0cd7c569ca09328bac\"},\"image\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/01\\\/info-js-600-198.png\",\"articleSection\":[\"javascript\",\"javascript basics\",\"javascript developer\",\"javascript fundamentals\",\"javascript learn\",\"js\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/\",\"url\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/\",\"name\":\"JavaScript Informational: Best of the Basics - App Development: Odds and Ends\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/01\\\/info-js-600-198.png\",\"datePublished\":\"2020-01-19T06:00:00+00:00\",\"dateModified\":\"2023-08-20T01:27:42+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#primaryimage\",\"url\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/01\\\/info-js-600-198.png\",\"contentUrl\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/01\\\/info-js-600-198.png\",\"width\":600,\"height\":198},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/2020\\\/01\\\/19\\\/javascript-informational-best-of-the-basics\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"JavaScript Informational: Best of the Basics\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/\",\"name\":\"App Development: Odds and Ends\",\"description\":\"Providing insights into a career of apps and utilities that I&#039;ve conceptualized, designed, and developed; complemented with developmental journeys, findings, observations, and challenges encountered along the way.\",\"publisher\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/#\\\/schema\\\/person\\\/87980b154db7bd0cd7c569ca09328bac\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/#\\\/schema\\\/person\\\/87980b154db7bd0cd7c569ca09328bac\",\"name\":\"Keith D Commiskey\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/08\\\/keith-sac-01.jpg\",\"url\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/08\\\/keith-sac-01.jpg\",\"contentUrl\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/08\\\/keith-sac-01.jpg\",\"width\":113,\"height\":117,\"caption\":\"Keith D Commiskey\"},\"logo\":{\"@id\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/08\\\/keith-sac-01.jpg\"},\"description\":\"Web App Creator; Former Flutter Developer; Former Front End Developer; Former Technical Graphics.\",\"sameAs\":[\"https:\\\/\\\/kdcinfo.com\\\/blog\",\"https:\\\/\\\/www.linkedin.com\\\/in\\\/commiskey\"],\"url\":\"https:\\\/\\\/kdcinfo.com\\\/blog\\\/author\\\/kdc4wp\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"JavaScript Informational: Best of the Basics - App Development: Odds and Ends","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/","og_locale":"en_US","og_type":"article","og_title":"JavaScript Informational: Best of the Basics - App Development: Odds and Ends","og_description":"Best of the Basics: JavaScript Informational JavaScript Informational: Best of the Basics: A full run through for entry- and mid-level developers looking for some solid","og_url":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/","og_site_name":"App Development: Odds and Ends","article_published_time":"2020-01-19T06:00:00+00:00","article_modified_time":"2023-08-20T01:27:42+00:00","og_image":[{"width":600,"height":198,"url":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2020\/01\/info-js-600-198.png","type":"image\/png"}],"author":"Keith D Commiskey","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Keith D Commiskey","Est. reading time":"13 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#article","isPartOf":{"@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/"},"author":{"name":"Keith D Commiskey","@id":"https:\/\/kdcinfo.com\/blog\/#\/schema\/person\/87980b154db7bd0cd7c569ca09328bac"},"headline":"JavaScript Informational: Best of the Basics","datePublished":"2020-01-19T06:00:00+00:00","dateModified":"2023-08-20T01:27:42+00:00","mainEntityOfPage":{"@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/"},"wordCount":2698,"commentCount":2,"publisher":{"@id":"https:\/\/kdcinfo.com\/blog\/#\/schema\/person\/87980b154db7bd0cd7c569ca09328bac"},"image":{"@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#primaryimage"},"thumbnailUrl":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2020\/01\/info-js-600-198.png","articleSection":["javascript","javascript basics","javascript developer","javascript fundamentals","javascript learn","js"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/","url":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/","name":"JavaScript Informational: Best of the Basics - App Development: Odds and Ends","isPartOf":{"@id":"https:\/\/kdcinfo.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#primaryimage"},"image":{"@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#primaryimage"},"thumbnailUrl":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2020\/01\/info-js-600-198.png","datePublished":"2020-01-19T06:00:00+00:00","dateModified":"2023-08-20T01:27:42+00:00","breadcrumb":{"@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#primaryimage","url":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2020\/01\/info-js-600-198.png","contentUrl":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2020\/01\/info-js-600-198.png","width":600,"height":198},{"@type":"BreadcrumbList","@id":"https:\/\/kdcinfo.com\/blog\/2020\/01\/19\/javascript-informational-best-of-the-basics\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/kdcinfo.com\/blog\/"},{"@type":"ListItem","position":2,"name":"JavaScript Informational: Best of the Basics"}]},{"@type":"WebSite","@id":"https:\/\/kdcinfo.com\/blog\/#website","url":"https:\/\/kdcinfo.com\/blog\/","name":"App Development: Odds and Ends","description":"Providing insights into a career of apps and utilities that I&#039;ve conceptualized, designed, and developed; complemented with developmental journeys, findings, observations, and challenges encountered along the way.","publisher":{"@id":"https:\/\/kdcinfo.com\/blog\/#\/schema\/person\/87980b154db7bd0cd7c569ca09328bac"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/kdcinfo.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/kdcinfo.com\/blog\/#\/schema\/person\/87980b154db7bd0cd7c569ca09328bac","name":"Keith D Commiskey","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2023\/08\/keith-sac-01.jpg","url":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2023\/08\/keith-sac-01.jpg","contentUrl":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2023\/08\/keith-sac-01.jpg","width":113,"height":117,"caption":"Keith D Commiskey"},"logo":{"@id":"https:\/\/kdcinfo.com\/blog\/wp-content\/uploads\/2023\/08\/keith-sac-01.jpg"},"description":"Web App Creator; Former Flutter Developer; Former Front End Developer; Former Technical Graphics.","sameAs":["https:\/\/kdcinfo.com\/blog","https:\/\/www.linkedin.com\/in\/commiskey"],"url":"https:\/\/kdcinfo.com\/blog\/author\/kdc4wp\/"}]}},"_links":{"self":[{"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/posts\/24","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/comments?post=24"}],"version-history":[{"count":1,"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/posts\/24\/revisions"}],"predecessor-version":[{"id":176,"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/posts\/24\/revisions\/176"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/media\/175"}],"wp:attachment":[{"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/media?parent=24"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/categories?post=24"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kdcinfo.com\/blog\/wp-json\/wp\/v2\/tags?post=24"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}