teleren/devto huggingface dataset:
🔥 LazyRecon: A Powerful Tool for Web Reconnaissance 🔥
Tags: security
Published: 2023-04-24 13:30:00

Today I am sharing a tool that I have been using for a while, which has helped me automate some tedious tasks of reconnaissance and information gathering of web applications. The tool is called LazyRecon, and it was developed by nahamsec, a well-known bug bounty hunter and security researcher.

LazyRecon is a script that performs various subtasks such as subdomain enumeration, port scanning, and content discovery, and also grabs a screenshot of responsive hosts using different tools and techniques. It also generates interactive HTML report that you can use for further analysis or reporting. LazyRecon is fast and easy to use


If you are interested in trying out LazyRecon, you can find it on [GitHub link](https://github.com/nahamsec/lazyrecon
)

I hope you find this tool helpful. 

![Recon](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/noi8rp3gfql768v9g49d.gif)
3 Ways To Enforce Object Immutability In JavaScript
Tags: webdev, javascript, tutorial, react
Published: 2023-04-24 13:19:51

> What happens when an Unstoppable Force meets an Immutable Object?


![An Immutable Object](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xofmd8hacmlqfvkh2wzu.png "An Immutable Object")

## Immutability
In **JavaScript,** **Object Immutability** means that once you have made an object **immutable,** its **properties** cannot be **added,** **deleted,** or **modified** at any time.

This is **important** because it helps **prevent unwanted side effects** from occurring, making your code **more predictable** and **easier to reason about.**

---

> Here are **3 ways** you can make an **object immutable** in **JavaScript,** ordered by the level of **integrity** they retain.

### Object.preventExtensions()
`Object.preventExtensions()` will **prevent new properties** from being **added** to an **object.**

![Demo of Object.preventExtensions()](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/d6wawim5vaob04ss8bio.png "Demo of Object.preventExtensions()")

However, it still allows the **deletion of properties** and **modification of values** from an **object.**

You can check whether an **object** is **extensible** by using `Object.isExtensible()`

### Object.seal()
`Object.seal()` will perform `Object.preventExtensions()` on it and also **prevent** the **deletion of properties.**

![Demo of Object.seal()](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bzef0plod6rtdlc0ig9m.png "Demo of Object.seal()")

However, it still allows the **modification of values** of an **object.**

You can check whether an **object** is **sealed** by using `Object.isSealed()`

### Object.freeze()
`Object.freeze()` will perform `Object.seal()` on it and also **prevent** the **modification of values** of an **object.**


![Demo of Object.freeze()](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ef5x4kp3oqgcum5chxwl.png "Demo of Object.freeze()")

You can check whether an **object** is **frozen** by using `Object.isFrozen()`

`Object.freeze()` is the **highest** level of **integrity** that **JavaScript** offers.

## Extras
- All of the above methods are applied **shallowly** on the **object.** This means that if you have an **object** within an **object,** the **inner object** would still be **mutable.**
- To perform a **deep operation** instead of a **shallow** one, you have to implement your own **recursive** function. [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/freeze) has provided a working example.

![MDN’s recursive deep freeze example](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5l11vo49x8te6mlgsug2.png "MDN’s recursive deep freeze example")

You can play with the examples above in this [JSFiddle.](https://jsfiddle.net/MorningLit/ng2w71t9/)
{% embed https://jsfiddle.net/MorningLit/ng2w71t9/ %}
---

If you felt that you have learned something new, do feel free to **follow** 🥰, **react** 💖 or write a **comment** ✍️!
It helps makes me create and share more valuable content for **you** to become a better **Web Developer!** 🤗
Saving 30% on costs and improve infrastructure reliability with profiling
Tags: profiling, node, troubleshooting, reliability
Published: 2023-04-24 13:13:47

# Scenario

As the technical co-founder of MyStoryViewer, a SaaS product that automated Instagram tasks for customers, I was responsible for full-stack web development and cloud engineering. However, as we began to scale and reached 600 concurrent workers, the product's performance suffered, and our customers began to complain.

If you want to read more about the underlying infrastructure, I've written [this post](https://dev.to/mrmavin/hundreds-of-bot-instances-to-the-back-end-using-redis-147e) about how I've managed to set-up workers.

# Problem

The software responsible for processing customer data was a NodeJS (Typescript) application running concurrently on large servers.

To troubleshoot the problem of degraded performance, I profiled the application at runtime to determine whether there were any issues causing the degradation.

# Solution

I started using ClinicJS Doctor to profile my software, and as shown in the results, there were issues with memory usage and event loop delays.

![NodeJS Clinic Profiling Results](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/u8f3ybmp0fvk986frlyy.png)

The problem was clear: something was using too much memory.

Since I was also the developer, I knew that a function I had written was retrieving data from the Instagram API. The API provided information about a profile, and I was storing all of the retrieved data in an array. Since I was processing 500 profiles for each iteration, I had megabytes of unnecessary data stored in memory. The solution was to only save relevant data from the API in memory.

# Results

With a single fix, I managed to cut costs and stop receiving complaints from customers.

The workers were running in parallel on big servers, and with this improvement in memory usage, I could run more instances per server, reducing costs by around 30%. Additionally, since the workers stopped crashing, I was able to improve infrastructure reliability and customer satisfaction.

On a personal level, I discovered a new way to troubleshoot and improve performance issues.

# Conclusion

This article is part of a series where I write about production use cases as a cloud engineer. The focus is on meeting business needs, working as a team, and personal growth.

If you find this article useful or want to share your thoughts about it, feel free to write a comment. I would be happy to read it.

As a side note, I'd like to add that this article was written with the help of AI.

See you in the next chapter!
New journey begins......
Published: 2023-04-24 13:00:40

I've been longing to write about how I got into the tech industry. I'm an undergraduate studying business computing, in essence. My career path was rather different because I originally intended to study mechanical engineering but decided against it in favor of a business major so that I could, as they say, "enjoy campus life." 
During my final year of college, I developed a love for technology. I even began going to tech-related events and learning for myself through w3school and codecademy.

---

 I eventually lost self-pace control and made the decision to look for a boot camp where I could genuinely collaborate with other peers.I got a partial scholarship to attend Moringa School to study the vanilla programming languages of Python and JavaScript as well as the React.js library and Flask framework. 

---

I will provide updates on my experience in addition to thorough information on the resources I believe are helping me.Follow along......
C++ Takrorlash Operatori (While, Do While)
Tags: webdev, beginners, cpp, programming
Published: 2023-04-24 12:53:01

Assalamu aleykum bugun siz bilan takrorlash operatorlari qanchali ahamiyatga ega ekanligni o'rganamiz.
Misol uchun biz consolega `"Hello World"` degan so'zni 100 marta chiqarmoqchi bo'lsam 100 marta cout deb yozib chiqishim kerak bo'ladi, leykin oson yoli xam mavjud qayta qayta yozmaslik uchun bizga `Loop` kerak bo'ladi.

Takrorlash qadamini amalga oshirish uchun `while` kalit so'zidan foydalanamiz. shart orqali tskil hosil bo'ladi. quyidagi sintaksisni o'zingizga formula sifatida yodlab quying.

```
while (<Shart>) 
{
  // tsikl tanasi
}
```

**Misol uchun** siz `Hello World` degan so'zni 10 marta ekranga chiqarmoqchi bo'lsangiz Loop da foydalansangiz ishingiz ancha oson bo'ladi.

```
#include <iostream>

using namespace std;

int main()
{

int i = 1;

while(i <= 10)
{

cout << "Hello World" << i << endl;
i++;

}
   
   return 0;
}
```

**Do/While Tsikl**

`do/while` va `while` ikkisi ham tskil hisoblanadi. birinchisini ikkinchisidan farqli jihati shundaki birin `do/while` avval shartni bajarib keyin tekshiradi. `while `esa avval shart bajariladi agar to'g'ri bo'lsa tsikl tanasidagi kod ishlatiladi. quyidagi `do/while` sintaksisini yodda saqlashingiz zarur bo'ladi.

```
do 
{
  // tsikl tanasi
}
while (<Shart>);
```

`Yuqoridagi Misoldagi shartga muafiq shuni biz do/while da ishlab ko'ramiz.`

```
#include <iostream>

using namespace std;

int main()
{

int i = 1;

do
{
  cout << "Hello World" << i << endl;
  i++;
}
while(i <= 10);


  return 0;
}
```

`Unutmang! tskil aylanayotgan vaqtda bog'liq bo'lgan o'zgaruvchini o'zgartirishni unutmang. agar qiymatini o'zgartirmasangiz tsikl tugamaydi.`
Use Firebase? localStorage? Or both?
Tags: firebase, javascript, webdev, beginners
Published: 2023-04-24 12:39:58

During my coding journey, creating this app allowed me to put into practice all the concepts I have learned. Specifically, I took the opportunity to become more proficient in using styled components and React Router, two essential tools for React development.

As I developed the app, one of the most significant challenges I encountered was determining the best way to store flashcard data and track their state. The purpose of the app was to help students revise vocabulary they had learned since third grade from their textbooks.

Initially, I considered uploading every single flashcard to Firebase. However, I soon realized that this approach would be overly complicated and burdensome. Additionally, it would require each student to create a registered account and log in, which would create significant hassle, especially since the app's goal was to be simple and straightforward.

After exploring various options, I decided to use localStorage as the most accessible and straightforward solution for students to track their flashcard revision progress. The main master deck would be stored in Firebase and only be accessible to teachers.

Implementing the Firebase feature presented a challenge since I was not very familiar with the technology. However, I eventually succeeded in uploading the master deck to Firebase and retrieving the main data. This achievement was one of the project's highlights.

```jsx
 /* Upload initial data to Firebase */
  function writeFlashcardData(decks: FlashcardSetData[]) {
    const db = getDatabase();
    set(ref(db, 'flashcards'), {
      decks,
    });
  }

  /* Fetching flashcard from Firebase*/
  const fetchFlashcardHandler = useCallback(async () => {
    setIsLoading(true);
    setError(null);
    try {
      const response = await fetch(
        'https://english-flashcards-app-962bb-default-rtdb.asia-southeast1.firebasedatabase.app/flashcards.json'
      );
      if (!response.ok) {
        throw new Error('An error has occurred');
      }

      const data = await response.json();
      setDeck(data.decks);

      // Obtain all of the cards arrays, join them and flatten it
      const decksArr = [];
      for (let i = 0; i < data.decks.length; i++) {
        decksArr.push(data.decks[i].cards);
      }
      const flattenedDecksArr = decksArr.flat();
      setAllCards(flattenedDecksArr);
    } catch (error: any) {
      setError(error.message);
    }
    setIsLoading(false);
  }, []);

  useEffect(() => {
    if (deck.length === 0) {
      writeFlashcardData(deckData);
      fetchFlashcardHandler();
    }
  }, [deck.length]);
  ```

Hoping to implement user authentication for the teachers to login in the future using Firebase!
Explain IntersectionObserver Like I'm Five
Tags: javascript, tutorial, beginners
Published: 2023-04-24 12:37:54

Okay kiddo, so imagine you're playing hide-and-seek with your friends, and you're trying to find them when they hide behind a tree.

Now, think of the tree as a webpage element that you want to keep an eye on, and your eyes as the Intersection Observer.

The Intersection Observer is like your big brother who watches over you and tells you when your friends come out from behind the tree. It observes if any part of the tree is visible in your line of sight and then alerts you that your friends are hiding there.

In programming terms, the Intersection Observer is a tool in JavaScript that helps you keep an eye on specific elements on a webpage and see if they come into or go out of view.

For example, let's say you have a long webpage with lots of content, and you want to know when a specific section comes into view, like a picture or a video. The Intersection Observer can help you do that without constantly checking the page yourself.

You can also use the Intersection Observer to lazy load images, meaning you only load images when they're visible on the page. This can speed up your webpage and make it more efficient.

In short, the Intersection Observer helps you keep an eye on webpage elements and lets you know when they come into or go out of view.

Why did the programmer quit his job? Because he didn't get arrays! 😂
How to create a landing page in 3 steps
Tags: javascript, webdev, beginners, programming
Published: 2023-04-24 12:37:35

**What is a landing page?
**A landing page is a specific webpage that is designed to persuade visitors to take a particular action, such as filling out a form, making a purchase, or subscribing to a newsletter. Landing pages are often used in digital marketing campaigns to help businesses convert website visitors into customers or leads.

Landing pages are typically designed to be simple and focused, with a clear call-to-action (CTA) that encourages the visitor to take the desired action. They may include elements such as a headline, subheadings, images or videos, bullet points highlighting benefits or features, and a form or button for the visitor to complete the desired action. continue reading [how to create a landing page ](https://hfnewss.com/how-to-create-a-landing-page-in-3-steps/)
My project got a shiny new Chrome Extension!
Tags: clojure, buildinpublic, opensource
Published: 2023-04-24 12:13:29

I have few days off at work, so a good opportunity to work on my projects!

Today's post is about the new Unrefined's Chrome Extension, which should streamline the job of EMs.

Get it here https://fpsd.codes/announcing-unrefineds-chrome-extension.html

p.s. It is exciting to build in public, I feel more encouraged to make progress and I am procrastinating way less than usual!
Join the Free Digital Identity Forum and Make a Difference: Collaborate with Developers to Shape the Future of Digital Identity
Tags: webdev, devops, community, discuss
Published: 2023-04-24 12:12:23

As developers, we have the power to shape the future of digital identity. Every time we create an application, a website, or any digital product, we contribute to the digital identity of our users.

Digital identity is how we are recognized and identified in the digital world, and it affects every aspect of our lives: from our online security to our access to resources and services. That's why it's crucial for developers to take an active role in shaping the future of digital identity. And one of the best ways to do that is by joining the Free Digital Identity Forum.

The Free Digital Identity Forum is a global community of developers, experts, and advocates who are working together to create a solution that is accessible, equitable, and meets the needs of everyone. By joining this forum, you'll have the opportunity to collaborate with other developers from around the world, share your expertise, and learn from others. 

You'll also have access to the latest tools, technologies, and best practices related to digital identity.

But why should you volunteer your time and expertise to shape the future of digital identity? The answer is simple: because it matters. Digital identity is a critical issue that affects billions of people around the world, and it's becoming increasingly complex and challenging. By volunteering for this cause, you'll have the opportunity to make a real difference in people's lives, and contribute to a more secure, inclusive, and equitable digital world.

Joining the Free Digital Identity Forum is also a great way to build your skills, expand your network, and gain experience working on a global project. You'll have the opportunity to work with other developers who share your passion for digital identity, and learn from their diverse perspectives and experiences. You'll also have the chance to contribute to open-source projects, which can be a valuable addition to your portfolio and resume.

But perhaps the most rewarding aspect of joining the Free Digital Identity Forum is the sense of purpose and fulfillment that comes with volunteering for a worthy cause. By contributing your expertise to this project, you'll be making a positive impact on society and helping to make the world a better place. You'll also have the opportunity to meet new people, make new friends, and form lasting connections with others who share your values and vision.

So if you're ready to be a part of something meaningful and contribute to a worthy cause, **join the Free Digital Identity Forum today! You can sign up at** [](https://www.internetidentitycard.com/)https://www.internetidentitycard.com
10 more Javascript Challenges!
Tags: webdev, javascript, challenge, codenewbie
Published: 2023-04-24 12:06:46

Do you know Javascript? After the success of the [previous video](https://youtu.be/8gGuu9c9miY), I've decided to make a second one with 10 more challenges to test your knowledge of the language.

These are 4 out of the 10 challenges you'll find in the video:

{% youtube wE-6CswAE64 %}

---

The `++` operator is really handy and you can put it either before or after the variable. But do you know the difference between the two?

```js
let value = 3;
console.log(value++);
console.log(++value);
```

---

You can use `_` and the letter `e` in numbers and they're still valid!


```js
const THE_ANSWER = 1_2 + 3e1;

console.log(THE_ANSWER);
```

---

Isn't the output here supposed to be `7` on both cases? Actually, none of them is `7`!


```js
const x = "5";

console.log(1 + 1 + x);
console.log(x + 1 + 1);
```

---

Can you spot any unintended side effect here?

```js
let me = { name: "Leonardo", socials: { twitter: "@balastrong" } };

let luca = { ...me };
luca.name = "Luca";
luca.socials.twitter = "@puppo92";

console.log(me);
console.log(luca);
```

---

If you're curious about the answers, you can find them in the video below. I hope you enjoy it!

{% youtube 79R_ys7a8Aw %}

In the video above, I go through all challenges and show the answer, but I also recorded a slower version where I actually explain them in more detail. If you're curious and want to learn more, you can find it here:

{% youtube wE-6CswAE64 %}

Let me know how many did you got right! :D

---

Thanks for reading this article, I hope you found it interesting!

I recently launched my Discord server to talk about Open Source and Web Development, feel free to join: https://discord.gg/bqwyEa6We6

Do you like my content? You might consider subscribing to my YouTube channel! It means a lot to me ❤️
You can find it here:
[![YouTube](https://img.shields.io/badge/YouTube:%20Dev%20Leonardo-FF0000?style=for-the-badge&logo=youtube&logoColor=white)](https://www.youtube.com/channel/UC-KqnO3ez7vF-kyIQ_22rdA?sub_confirmation=1)

Feel free to follow me to get notified when new articles are out ;)
{% embed https://dev.to/balastrong %}
SEO explained: Ultimate Beginners Guide
Tags: seo, onpage, keywords, offpage
Published: 2023-04-24 12:01:06

What is SEO?
Search Engine Optimization means optimizing our website according to google guidelines to rank our website at the top and increase its visibility.

How to Optimize the website? What factors to consider?

Google’s top priority is its users. It has algorithms running to deliver relevant data to users. To understand SEO you have to think like Google’s search engine . Let us forget about all these search engines. If I ask you to get all the business information in our locality, What will you do? You will take a directory and put all the information about several business categories (like address, number, etc)  and start organizing the data (in alphabetical order). Google also does the same thing. It has crawlers and Indexers which crawl and index our website and whenever a user is typing a query google fetches relevant results and these results appear on SERP. 

What are Crawler and Indexer?

The crawler collects the data from the website and the indexer store and organizes the data in segments whenever the user types a query then the indexer fetch the relevant results.

Competition Analysis
The first thing to do in SEO is to see for what keywords your competitor is ranking and where they are getting backlinks. Semrush is a paid tool that provides all this data. Do keyword and backlink gap analysis. Analyze and organize all the data and see how you can improve the ranking of your website. 

 Read More: Technical SEO

Keyword Research
Keywords are one of the important factors for SEO. For crawler and indexer in order to know what your website is about you need to repeat those words users are searching for and use those words. As mentioned above Google wants to show relevant data to the users. That is why you need to find these keywords. 

Keyword Planner Tools

1)Google Keyword Panner

2)Keyword.io

3)kwfinder

Once you got all the data export it into excel/google sheets and filter out the keywords.

 

[OnPage SEO](https://digigon.in/seo/)
Onpage seo is making changes in the website according to google guidelines so that it ranks on the top .This increases organic traffic to the website. 

Onpage Elements

Domain Name
Title Tag
Internal links
Https
Meta Tags
Image optimization
Keywords
Content
Schema
Url
Heading
code
 For more details click here : 12 Essentials Factors of OnPage SEO :Beginners Guide
 
Technical SEO
Techinal SEO is to improve the techinal factors of website such as site speed and page size so that the crawlers can crawl the website efficiently.

Tools for Speed Analysis.

Google speed Insights.
Pingdom
GTMetric
Webpage Text.
Read More : Technical SEO
 
OffPage SEO
OffPage SEO is about building Quality backlinks for the website. Backlinks are references from other websites. Backlinks are given from Anchor tag.



Types of Backlinks:

 One Way Linking.
Two way Linking.
Three Way Linking.
Blueprints for the IoT Hackathon 2023
Tags: iot, cumulocity, hackathon, eventsinyourcity
Published: 2023-04-24 11:55:08

🚨 Attention IoT innovators! 🚨

The IoT Hackathon 2023 has just unveiled an array of devices and blueprints to elevate your creativity and problem-solving skills. Seize the opportunity to work with devices like the Bosch XDK, Revolution Pi, and Dobot Robot Arm.

Explore the practical blueprints we have provided, from optimizing the output of your fields & sheds with Smart Farming to having a fully automated beer bar.

Collaborate with other IoT enthusiasts, develop innovative solutions, or just bring your IoT skills and have some fun. Find out more about the devices and blueprints, and secure your place at the #Cumulocity #IoT Hackathon at IUG 2023 in June: https://bit.ly/3mMVKsh