Добавлено: 29 апреля 2023 г.
JavaScript is a versatile programming language that allows developers to create dynamic and interactive web applications. One common task in web development is to refresh or reload a web page, either to update its content or to trigger certain actions.
In this article, we will explore different ways to refresh a page in JavaScript and understand the pros and cons of each approach.
Why refresh a page in JavaScript?
Refreshing a web page...
далее...
Добавлено: 26 февраля 2023 г.
Error handling with Async/Await in JS
This will be a small article, based on some issues I picked up during code reviews and discussions with other developers. This article is rather focused on the novice JS developers.
A Simple Try Catch
Let’s start with the simple try...catch example.
function thisThrows() {
throw new Error("Thrown from thisThrows()");
}
try {
thisThrows();
} catch (e) {
console.error(e);
} finally {
console.log('We do cleanup here');
}
// Output:
// Error: Thrown from thisThrows()
// ...stacktrace
//...
далее...
Добавлено: 3 февраля 2022 г.
What if programming languages were stocks? And you had to make a portfolio to fetch good returns in 2022?
You probably have seen various surveys and analyses listing the most popular programming languages. Those cover the universe of programming languages, like the S&P 500 does for the stock market. What would be the best portfolio for you to be successful and outperform the rest?
Of course, it depends on the risk profile,...
далее...
Добавлено: 30 марта 2021 г.
Let’s start the battle TypeScript vs JavaScript with an introduction of both technologies. JavaScript is a scripting language, that was developed by EMCA’s Technical Committee and Brendan Eich. It works perfectly in web-browsers without the help of any web-server or a compiler. It allows you to change HTML and CSS in the browsers without a full page reload. That is why it is used to create dynamic and interactive web...
далее...