teleren/devto huggingface dataset:
Implementing Star Ratings in Google Search Results for Your Website
Tags: webdev, javascript, beginners, programming
Published: 2023-07-02 02:46:04

Title: Implementing Star Ratings in Google Search Results for Your Website


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sl21znxy0h3ee0ghu172.jpg)

Introduction:
Adding star ratings to your website's search results in Google can greatly enhance its visibility and attract more users. Google displays star ratings as rich snippets, providing valuable information about the quality and reputation of your website. In this article, we will explore how to implement structured data using schema.org's Review markup to ensure that your star ratings appear in Google search results.

Step 1: HTML Markup:
To begin, you need to add the necessary schema.org Review properties to your HTML code. The following example demonstrates the markup structure:

```html
<div itemscope itemtype="http://schema.org/Review">
  <span itemprop="name">Great Product</span>
  <div itemprop="itemReviewed" itemscope itemtype="http://schema.org/Thing">
    <span itemprop="name">Your Website</span>
  </div>
  <div itemprop="reviewRating" itemscope itemtype="http://schema.org/Rating">
    <meta itemprop="worstRating" content="1">
    <span itemprop="ratingValue">4.5</span> out of <span itemprop="bestRating">5</span> stars
  </div>
  <span itemprop="author" itemscope itemtype="http://schema.org/Person">
    <span itemprop="name">John Doe</span>
  </span>
  <meta itemprop="datePublished" content="2023-07-01">
  <div itemprop="reviewBody">
    This website provides excellent service. I highly recommend it!
  </div>
</div>
```

Step 2: Structured Data Testing:
Once you've added the Review markup to your HTML, it's crucial to test the structured data for accuracy and proper implementation. You can utilize Google's Structured Data Testing Tool or the Rich Results Test to validate that your markup is correctly interpreted by Google's algorithms.

Step 3: Validating and Displaying:
Google determines when to display star ratings in search results based on various factors, including relevance and search intent. While correctly implementing structured data increases the chances of your star ratings appearing, Google has the final say in deciding the eligibility and presentation of search result features.

Conclusion:
By implementing structured data using schema.org's Review markup, you can increase the visibility and attractiveness of your website in Google search results. Incorporating star ratings provides valuable information to users, enhances your website's reputation, and helps drive more traffic. Remember to follow Google's guidelines for structured data implementation and focus on delivering authentic and relevant reviews.
Styling active route menu item in laravel
Tags: laravel, beginners
Published: 2023-07-02 02:21:01

You can check if the current route is active just with

```
request()->routeIs('admin.cities')
```

Or even sub-routes (like editing, creating, or whatever with

```
request()->routeIs('admin.cities*')
```

If you prefer to use the route facade, you still can do that with

```
Route::named('admin.cities*')
```

By using the * character, you can apply the active class to sub-menus easily:

```
routeIs('admin.cities*') ? 'active' : '' }}"> Cities
routeIs('admin.cities.index') ? 'active' : '' }}><a>List</a>
routeIs('admin.cities.create') ? 'active' : '' }}><a>Create</a>
```
Crypt::OpenSSL::SignCSR released
Published: 2023-07-02 02:17:06

I released a new version of https://metacpan.org/pod/Crypt::OpenSSL::SignCSR a #perl module to allow you to sign a Certificate Signing Request (CSR) from perl.  I was looking for a module to allow me to create a self signed certificate from perl directly and was not able to find one.  I could have called the openssl command to create one but that seemed like cheating.

It's a XS based module which is a Frankenstein merger of #perl and #c that is fun to work with.  Basically I grabbed the parts of OpenSSL C code that I needed and married it to #perl.  It went very well and was a lot easier than I expected.  I did have to spend some time tracking down issues with different OpenSSL versions but it does what I want.
Clases en JavaScript
Tags: javascript, beginners, spanish
Published: 2023-07-02 01:19:44

Clases en Javascript. La construcción del objeto tiene sus peculiaridades. La estructura es relativamente parecida a cualquier otro lenguaje de programación, como se muestra a continuación.


![Ejemplo de clase](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1ebhy9fihvzitz4ech20.png)

Un constructor es esencial ya que nos ayuda a inicializar las variables de clases o propiedades del objeto. Algo particular es que se ocupa la palabra reservada (this) para asignar un valor a la propiedad del objeto.


![Constructor de clases](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/325az990do6rh5kzp682.png)

Acá hay que tomar en cuenta que se crea un objeto vacío y con la palabra this se van agregando las propiedades sin necesidad de haberlas declarado antes. Los métodos de una clase son las acciones que puede hacer un objeto en este caso agregaríamos un método que sea para saludar, si te fijas no es necesario la palabra reservada function solo es necesario el nombre del método y agregar paréntesis.


![Funciones en clase](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jrscowml6oqzvvm2cpoh.png)

Para crear una instancia de un objeto se realiza de la siguiente manera. Es buena práctica que el nombre de la clase sea en mayúsculas para que se puedan diferenciar de una variable. Para acceder a los métodos de una clase se ocupa punto y el nombre del método.


![Instanciar una clase](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lrtsu2trx5l9x6d5g4wh.png)

Si este artículo te gusto o ayudo a comprender mejor los conceptos básicos de clases en JavaScript te agradecería bastante que me siguieras y compartieras mi contenido.
How to use Lens IDE with two different AWS profiles
Tags: aws, eks, k8s, lens
Published: 2023-07-01 19:30:45

---
title: How to use Lens IDE with two different AWS profiles
published: true
date: 2023-07-01 19:24:24 UTC
tags: AWS,EKS,K8S,LENS
canonical_url: https://habil.dev/how-to-use-lens-ide-with-two-different-aws-profiles/
---

## What is Lens IDE?
 ![How to use Lens IDE with two different AWS profiles](https://images.unsplash.com/photo-1515774004412-e3185c2a8217?crop=entropy&cs=tinysrgb&fit=max&fm=jpg&ixid=M3wxMTc3M3wwfDF8c2VhcmNofDF8fG11bHRpfGVufDB8fHx8MTY4ODIzOTMzNnww&ixlib=rb-4.0.3&q=80&w=2000)

The Lens IDE is a desktop application with a user-friendly interface for managing and interacting with Kubernetes clusters. It offers a centralized dashboard to view and manage multiple clusters, provides real-time metrics and logs, allows for easy deployment and management of applications, and offers various other features to simplify working with Kubernetes.

## The Problem

If there is only 1 profile in the AWS CLI, Lens IDE will not give you a problem, but when you start working with more than one profile, you begin to encounter problems.

Editing the active profile manually or rotating the access keys will start to tire you after a while.

I can offer you a solution to overcome this problem. Let's start.

## **Requirements**

- [aws-cli](https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2.html)
- [kubectl](https://kubernetes.io/docs/tasks/tools/)
- [awsp](https://github.com/johnnyopao/awsp)
- [open-lens](https://k8slens.dev/)

## Installation

Before starting the installation, let's ensure everything works with a single profile. To achieve this, let's complete the AWS CLI, then kubectl and finally Lens IDE installations.

After the initial single profile setup, you need to create AWS Profile with the following command:

```
aws configure --profile PROFILE_NAME
```

Example AWS CLI Config File:

```
[profile DEMO_1]
region = eu-central-1
output = json
[profile DEMO_2]
region = eu-central-1
output = json
```

Example AWS CLI Credential File:

```
[DEMO_1]
aws_access_key_id = XYZ
aws_secret_access_key = 123
[DEMO_2]
aws_access_key_id = ABC
aws_secret_access_key = 321

```

Install AWSP:

```
npm install -g awsp
```

Add the following to your `.bashrc` or `.zshrc` config

```
alias awsp="source _awsp"
```

Now you have installed awsp, if you execute `awsp` command in your terminal you can switch in your AWS Profiles.

One more step to achieve the goal. We need to add some environment variables to the kubectl config file.

Open the file and add the following environments for every profile.

```
users:
- name: demo@demo.eu-central-1.eksctl.io
  user:
    exec:
      apiVersion: client.authentication.k8s.io/v1alpha1
      args:
      - token
      - -i
      - dec14
      command: aws
      env:
      - name: AWS_PROFILE
        value: DEMO_1
```

## Conclusion

In this article, we learned how to create & manage multiple aws profiles and how to use these profiles with Lens IDE. I hope it was useful.

See you in the next article. 👻
Aplicando la Ciencia de Datos en DevOps: La Era del Data-Driven DevOps
Tags: devops, data, datascience, datadrivendevops
Published: 2023-07-02 01:10:36

La unión de dos mundos innovadores, DevOps y la ciencia de datos, ha llevado a la creación de un nuevo paradigma en el desarrollo de software: el Data-Driven DevOps. Al aplicar principios de la ciencia de datos a las operaciones de DevOps, podemos obtener una visión más profunda de nuestros procesos de desarrollo y mejorar su rendimiento y eficiencia. En este artículo, exploraremos cómo funciona esto y cómo puedes implementarlo en tus propios proyectos.

## La era del Data-Driven DevOps

El objetivo de DevOps es mejorar la colaboración entre los equipos de desarrollo y operaciones para lograr un flujo de trabajo más eficiente y eficaz. Con el advenimiento del Data-Driven DevOps, este objetivo se lleva un paso más allá, utilizando técnicas de ciencia de datos para informar y optimizar los procesos de DevOps.
En la era del Data-Driven DevOps, los datos recopilados a través de diversas etapas del ciclo de vida del desarrollo de software se utilizan para alimentar modelos predictivos y prescriptivos. Estos modelos pueden ayudar a identificar posibles cuellos de botella, predecir problemas antes de que ocurran, e incluso sugerir formas de mejorar la eficiencia del proceso de desarrollo.

## Implementando la Ciencia de Datos en DevOps

Para implementar la ciencia de datos en DevOps, es importante empezar por la recopilación de datos. Esta recopilación puede venir de múltiples fuentes, incluyendo registros de sistema, métricas de rendimiento, y registros de errores. El siguiente paso es el análisis de estos datos, que puede implicar técnicas estadísticas, aprendizaje automático, e incluso inteligencia artificial.
Por ejemplo, puedes utilizar el análisis de series temporales para identificar patrones en los registros de sistema, lo que podría ayudarte a predecir cuándo es probable que ocurran ciertos problemas. O puedes utilizar algoritmos de aprendizaje automático para analizar los registros de errores y identificar las causas más comunes de fallos.

## Conclusión

El Data-Driven DevOps representa un nuevo horizonte en el desarrollo de software. Al combinar los principios de la ciencia de datos con las prácticas de DevOps, podemos mejorar la eficiencia de nuestros procesos de desarrollo y proporcionar un mejor servicio a nuestros usuarios.
En el futuro, esperamos ver aún más innovaciones en este espacio. Así que si estás en el mundo del desarrollo de software y te interesa tanto DevOps como la ciencia de datos, definitivamente deberías considerar explorar el Data-Driven DevOps.
Shared user database
Tags: webdev, mongodb, node, firebase
Published: 2023-07-02 00:39:40

hey guys, does anyone have an idea on how can I have multiple projects, each one using its own database with its own sets of collections But they share the same user collection. should I do separate databases ? but then how can I use functions like .populate() if am using MongoDB or how can I add a ref to users Id if they are not in the same database. 
Thank u.
What are functional and non-functional requirements?
Tags: requirements, functionalrequirements, nonfunctionalrequirements, analysis
Published: 2023-07-02 00:33:51

Hello 👋

This is my first post on dev.to. I am starting to write while improving my english and tech skills. To start, I will write about requirements and their two main types: **functional** and **non-functional** requirements.

Requirements are an essential part of developing a new software. They need to be clearly defined on the road that leads to a successful project. There is a lot of requirement types. Here I will focus in two types I think that are the main ones.

**Functional Requirements**
Functional Requirements are products features or functions that must be implemented to enable users to accomplish their tasks. These requirements must be clear to stakeholders in order to avoid future problems in the project. They define _all the things that the system must do_.
Here, some examples of functional requirements:

- Business rules that must be met.
- External interfaces of the system.
- Steps that the system must take in authentication.
- The reporting requirements.

**Non-Functional Requirements**
These are the requirements that _describe how the system works_ and they aren`t related with the system functionalities. Some examples are:

- Speed: How fast the system works, or some module should work.
- Capacity: What are the system limits.
- Usability: How easy the system is for its users. Is the things clearly enough? Could the user use the system without any problem?
- Reliability: How dependable the system is.

These are only some examples about non-functional requirements. There are a lot of other types.

I hope that you like the post. It`s my first try in english, so sorry about possible spelling errors, I will be better.

Thank you!
Bazaars BZR at the forefront of Cryptocommerce
Tags: bazaars, bzr, cryptocurrency, blockchain
Published: 2023-07-02 00:05:38


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ho28dsthesyp0crmm7y4.png)
[](https://bazaars.io)Bazaars BZR is a decentralized marketplace that allows users to buy and sell goods and services without the need for a third party. The platform is built on the Ethereum blockchain and uses smart contracts to facilitate transactions.
Cryptocommerce is a rapidly growing industry. In 2021, the global cryptocommerce market was valued at $321 billion and is expected to reach $1.2 trillion by 2028. This growth is being driven by a number of factors, including:
Increased acceptance of cryptocurrencies. More and more businesses are accepting cryptocurrencies as payment, which makes it easier for people to use crypto to buy goods and services.
Growing popularity of decentralized marketplaces. Decentralized marketplaces like Bazaars BZR offer a number of advantages over traditional e-commerce platforms, such as increased security and privacy.
Increased awareness of crypto. As more people learn about cryptocurrencies, they are becoming more interested in using them to buy goods and services.
Bazaars BZR is well-positioned to capitalize on the growth of cryptocommerce. The platform offers a number of features that make it attractive to both buyers and sellers, including:
Secure and transparent transactions. Bazaars BZR uses smart contracts to facilitate transactions, which ensures that they are secure and transparent.
Low fees. Bazaars BZR charges low fees for transactions, which makes it a cost-effective option for both buyers and sellers.
Global reach. Bazaars BZR is a global marketplace, which means that buyers and sellers can transact with each other from anywhere in the world.
As the cryptocommerce industry continues to grow, Bazaars BZR is well-positioned to capture a significant share of the market. The platform's features and global reach make it an attractive option for both buyers and sellers, and the growth of the cryptocommerce industry is likely to drive increased demand for Bazaars BZR's services.
Here are some additional factors that could contribute to Bazaars BZR's growth:
Partnerships with major brands. Partnerships with major brands would help to raise awareness of Bazaars BZR and attract new users.
Development of new features. The development of new features, such as a mobile app, would make Bazaars BZR more user-friendly and accessible to a wider audience.
Increased marketing efforts. Increased marketing efforts would help to raise awareness of Bazaars BZR and attract new users.
Overall, Bazaars BZR is well-positioned to capitalize on the growth of the cryptocommerce industry. The platform has a number of features that make it attractive to both buyers and sellers, and the growth of the industry is likely to drive increased demand for Bazaars BZR's services.
Alternative to Medium - Work in progress
Tags: vue, nuxt, flask, python
Published: 2023-07-01 23:16:47


Hello Guys,
as I can't post it on Reddit, I now post it here.

I am currently 14 years old, and I started building a Medium alternative, here you currently only see a screenshot, as it is a work in progress.

I want to ask for UI improvements. Likewise, I already know a lot of improvements myself that I am currently working on - but I am looking forward to all suggestions 😃

There is some kind of demo already running at [https://devsfordevs.com](https://devsfordevs.com), but it is also my old portfolio and yea, not that updated.

My current portfolio is https://www.benherbst.net/

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jpejecwn08qnuy6ga055.png)
Convenciones de commits en GIT
Tags: git
Published: 2023-07-01 23:10:11

### Formato del mensaje
```
<type>(<scope>): <subject>

<body>

<footer>
```

#### Primera línea del mensaje type, scope y subject

- `type` indica el tipo de cambio realizado
- `scope` parte que fue modificado
- `subject` mensaje breve y conciso del cambio realizado

```
fix(clients): Fix update client
```

#### type
Valores que se utilizan en `type`

`feat`: Se agregó nuevas características.

`fix`: Corrección de errores.

`docs`: Cambios en la documentación.

`style`: Cambios en la sintaxis o mejora el estilo del código, como la puntuación o la sangrado.

`refactor`: Refactoriza el código para que sea más limpio y legible.

`test`: Agregar o actualiza pruebas unitarias (test).

`chore`: Indica mantenimiento del código.

`perf`: Mejoras el rendimiento del código.

`build`: Mejora el proceso de compilación del proyecto.

`ci`: Mejora el proceso de integración continua del proyecto.

`cd`: Mejora el proceso de implementación continua del proyecto.

#### subject
- Iniciar con mayúscula
- No colocar punto al fina del mensaje
- Escribir de manera imperativa, como si daríamos una orden
- Se recomienda que el mensaje sea en ingles

#### body
- El body debe responder las preguntas ¿qué cambió? y ¿por qué? en vez del ¿cómo cambió?

#### footer
- Sirve para explicar un BREAKING CHANGE
JavaScript to Python- a few differences in syntax
Tags: codenewbie, javascript, python
Published: 2023-07-01 22:33:05

When you are learning a new programming language it can be hard to keep the syntax straight in-between the two languages. Here is a quick reference of some basic differences between JavaScript and Python.

**Naming Conventions-**

- JavaScript uses lowerCamelCase as a naming convention.

- Python uses the snake_case as a naming convention.
```
// JavaScript
aNewCupOfCoffee

# Python
a_new_cup_of_coffee
```
**Declaring variables-**

- JavaScript uses const, let, and var to declare variables.
- To declare a variable in Python, it is set to the value- variable = value.
```
// Variable in JavaScript
const kaiBear = "super fluffy pupper"

# Variable in Python
kai_bear = "super fluffy pupper"
```
**Creating Functions-**

- In JavaScript we create functions by using the function keyword and surrounding the function body in curly braces.

- To create a function in Python use the def keyword and add a colon after the parentheses.
```
// JavaScript function
function newRamenMenu(){
   // write code here
}
# Python function
def new_ramen_menu():
    # write code here
```
**Code Blocks-**

- JavaScript uses curly braces to group statements together.
- To create a code block in Python you indent (press the space bar 4 times) continuous lines of code. 

```
// A code block in JavaScript
if (a > 3){
  console.log(a);
}

# A code block in Python
if a > 3:
    print(a)
```
**Creating Comments-**
_Single line comments_

- Single line comments are written in JavaScript with two slashes(//).

- Python writes single line comments with a hashtag, or the pound sign (#)
```
// This is a comment in JavaScript

# This is a comment in Python
```
_Multi-line comments_
- Multi-line comments are written in JavaScript by starting with a  /* and ending with */.

- Python writes multi-line comments with a hashtag, or the pound sign (#) at the beginning of each line.

```
/*
This is a multi-line 
comment in JavaScript.
*/

#This is a multi-line
#comment in JavaScript.
```


Resources-
https://www.freecodecamp.org/news/python-vs-javascript-what-are-the-key-differences-between-the-two-popular-programming-languages/
https://www.educba.com/python-vs-javascript/
Install Notion on Ubuntu
Tags: linux, ubuntu, notion, tutorial
Published: 2023-07-01 22:22:12

- 1. Open terminal and execute the next commands:

```
echo "deb [trusted=yes] https://apt.fury.io/notion-repackaged/ /" | sudo tee /etc/apt/sources.list.d/notion-repackaged.list
```

- 2. 

```
sudo apt update
```

- 3.

```
sudo apt install notion-app-enhanced
```

- 4.

```
sudo apt install notion-app
```

---
✨ Done! ✨

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2w9dsql0o94alcdmsijb.png)


---
❗ **[2024] Troubleshoot installation issues** ❗

I noticed that some people had problems installing. Then follow these commands to install a stable desktop version:

1) If you still have the Notion app files on your system, uninstall them

```
sudo apt purge notion*
```
2) Now run this command to install a new version

```
sudo snap install notion-snap-reborn
```

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sxhcva546ks80jbjxils.png)