Today I studied basic and essential JavaScript concepts and I summarize them in this article to reinforce what I have learned and share good practices.
Variable types and good practices
var has function scope and can cause hoisting, which is why it is not recommended in modern code. let has block scope and allows reassignment, making it safer than var. const has block scope and does not allow reassigning the variable, although objects and arrays referenced by const can have their properties mutated. Practical recommendation: use const by default and use let only when you need to reassign, avoid var.
Template literals
Template literals allow interpolating variables, writing multiline strings, and evaluating expressions within the string. Conceptual example of using variables and console output span const nombre = Mariana; console.log Hola, ${nombre} span
Destructuring objects and arrays
Destructuring allows extracting values from objects and arrays into independent variables clearly. Example with object span const persona = { nombre: Mariana, edad: 26 }; const { nombre, edad } = persona; span Example with array span const numeros = [1, 2, 3]; const [uno, dos, tres] = numeros; span
Rest and Spread operators
Rest groups arguments or the remaining properties into an array or an object. Example of a function with Rest span function suma(...nums) { return nums.reduce((acc, n) => acc + n, 0); } span Spread allows expanding elements of an array or properties of an object to create new arrays or objects without mutating the originals. Examples span const arr1 = [1, 2]; const arr2 = [...arr1, 3, 4]; const obj1 = { a: 1 }; const obj2 = { ...obj1, b: 2 }; span
Exercises to practice
1- Create an object and extract properties using destructuring. 2- Create a function that receives n arguments and returns the sum using Rest. 3- Given the user object, extract the variables nombre and email using destructuring span const usuario = { nombre: Carlos, email: carlos@email.com, edad: 35 }; span 4- Given the array numeros, get the first and third elements in separate variables span const numeros = [10, 20, 30, 40, 50]; span 5- Create a function that receives any number of numbers using Rest and returns a new array containing those numbers plus the numbers 100, 200, 300 using Spread.
Fundamentals and modern syntax summarized
In summary, mastering let and const, using template literals for better readability, applying destructuring for cleaner code, and using Rest and Spread to manipulate data functionally are key fundamentals of modern JavaScript syntax.
About Q2BSTUDIO and services
Q2BSTUDIO is a custom software and application development company specialized in modern solutions for businesses. We offer custom software, custom applications, and artificial intelligence services tailored to real needs. We have experience in cybersecurity to protect infrastructures and sensitive data, and we offer AWS and Azure cloud services to deploy scalable and secure applications. Additionally, we develop business intelligence services and Power BI implementations to transform data into decisions, and we offer AI solutions for companies, AI agents, and custom artificial intelligence projects integrated with cloud architectures.
Why choose us
Choosing Q2BSTUDIO means working with a team that integrates custom software development and custom applications with experience in artificial intelligence and cybersecurity, ensuring secure, scalable, and results-focused solutions. We work with AWS and Azure cloud services, implement business intelligence services, and offer AI consulting for companies and AI agents for advanced automation.
If you want to strengthen your JavaScript skills or need a provider to create custom software, custom applications, artificial intelligence projects, cybersecurity, or integration with AWS and Azure cloud services, contact Q2BSTUDIO for a consultation aligned with your goals.


