JavaScript Arrays are a very flexible data structure and used as lists, stacks, queues, tuples (e.g. pairs), etc. Some
Creating Arrays, reading and writing elements:
You first need to undestand the concept of frontend tests.
You should not test the implementation but the behavior
You test like the end user
For instance, imagine a login screen with email and password inputs and a submit button
The test should input the email and the password, then click in the submit button.
tips to evolve as a developer
developers get stuck, paralized
https://www.oreilly.com/library/view/apprenticeship-patterns/9780596806842/ch04.html
Make It Stick https://www.amazon.com.br/Make-Stick-Science-Successful-Learning/dp/0674729013
(function () { | |
var url = 'https://i.kym-cdn.com/photos/images/newsfeed/001/331/288/371.png'; | |
var image = new Image(); | |
image.src = url; | |
image.width = 300; | |
image.style = 'position: fixed; bottom: 20px; transform: translateX(-1000px); transition: all 0.5s ease; animation: anim 2s 2s;'; | |
var style = document.createElement('style'); | |
style.innerHTML = '@keyframes anim { 15% { transform: translateX(-40px); } 25% { transform: translateX(-40px) rotate(45deg); } 50% { transform: translateX(-40px) rotate(0deg); } 75% { transform: translateX(-40px) rotate(45deg); } 90% { transform: translateX(-40px) rotate(0deg); } 99% { transform: translateX(-1000px) rotate(45deg); } }'; | |
document.body.appendChild(style); | |
document.body.appendChild(image); |
2019 update: this essay has been updated on my personal site, together with a followup on how to get started
2020 update: I'm now writing a book with updated versions of all these essays and 35 other chapters!!!!
If there's a golden rule, it's this one, so I put it first. All the other rules are more or less elaborations of this rule #1.
You already know that you will never be done learning. But most people "learn in private", and lurk. They consume content without creating any themselves. Again, that's fine, but we're here to talk about being in the top quintile. What you do here is to have a habit of creating learning exhaust. Write blogs and tutorials and cheatsheets. Speak at meetups and conferences. Ask and answer things on Stackoverflow or Reddit. (Avoid the walled gardens like Slack and Discourse, they're not public). Make Youtube videos
All libraries have subtle rules that you have to follow for them to work well. Often these are implied and undocumented rules that you have to learn as you go. This is an attempt to document the rules of React renders. Ideally a type system could enforce it.
A number of methods in React are assumed to be "pure".
On classes that's the constructor, getDerivedStateFromProps, shouldComponentUpdate and render.
Se você quiser adicionar mais algum tópico deixe seu comentário, o objetico é facilitar para os iniciantes ou aqueles que buscam dominar JavaScript, quais tópicos são importantes para dominar JavaScript.
São tópicos para quem sabe o minimo de JavaScript (declarar variáveis), a ordem em que eles aparecem são por importância para o dominio como um todo. Mesmo que você já tenha experiência com JS, recomendo que leia os links de cada tópico para fortalecer suas bases teóricas e ter um comportamento mais profundo da linguagem.
Lista originalmente criada e compilada por Vinicius Reis
Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.
(function(){ | |
var text = "Happy Birthday, Steve!", | |
length = text.length, | |
chr = 1, | |
ar = text.split(), | |
today = new Date(); | |
try { | |
if (window.console) { | |
if (console.clear && console.log) { | |
if (today.getDate() === 17 && today.getMonth() === 2) { |