development

How to create GraphQL API in Nest JS? Step by Step guidelines!

How to create GraphQL API in Nest JS? Step by Step guidelines!

Creating a GraphQL API in NestJS involves several steps. Here's a step-by-step theoretical guide: Step 1: Setup a New NestJS Project Install Nest CLI: npm install -g @nestjs/cli Enter fullscreen mode Exit fullscreen mode Create a New Project: nest new project-name Enter fullscreen mode Exit fullscreen mode Navigate to the Project Directory: cd project-name Enter fullscreen mode Exit fullscreen mode Step 2: Install GraphQL and Apollo Server Install Required Packages: npm install @nestjs/graphql graphql apollo-server-express Enter fullscreen mode Exit fullscreen mode Step 3: Configure GraphQL Module Create a GraphQL Module Configuration: Open src/app.module.ts and configure the GraphQL module: import {…
Read More
Higher Order Components (HOC) React

Higher Order Components (HOC) React

const UpdatedComponent = (Original Component) => { class NewComponent extends React.Component { constructor(){ this.state = { ... } } render(){ return( <OriginalComponent props/> ); } } return NewComponent; }; class OGComponent extends React.Component{ ... //available via (this.props..) } export default UpdatedComponent(OGComponent); Enter fullscreen mode Exit fullscreen mode Source link lol
Read More
Smart contracts privados con Solidity y Circom

Smart contracts privados con Solidity y Circom

ZK nos permite hacer aplicaciones con datos y ejecución privada. Esto abre la puerta a muchos nuevos casos de uso, como el que crearemos en esta guía: un sistema de votación anónimo y seguro combinando Circom y Solidity. Circom y dependencias Si aún no tienes circom, instálalo con los comandos a continuación. Yo estoy usando node v20 pero debería funcionar con otras versiones. curl --proto '=https' --tlsv1.2 https://sh.rustup.rs -sSf | sh git clone https://github.com/iden3/circom.git cd circom cargo build --release cargo install --path circom npm install -g snarkjs Enter fullscreen mode Exit fullscreen mode También vamos a ocupar las librerías de…
Read More
How to Create Your Own Memes Generator Project

How to Create Your Own Memes Generator Project

Project:- 3/500 Meme Generator Project Description The Meme Generator project is a web-based application that allows users to create their own memes. Users can upload images or provide image URLs, add custom text to the top and bottom of the image, adjust text size, and export the final meme as a PNG file. Features Image Upload: Upload an image from your local system. Image URL: Use an image from the web by providing its URL. Custom Text: Add and edit custom text at the top and bottom of the image. Text Styling: Adjust the font size of the text. Export…
Read More
Perl Weekly #671 – In-person and online events

Perl Weekly #671 – In-person and online events

Originally published at Perl Weekly 671 Hi there! Last week I included an entry about the Getting started with Docker for Perl developers workshop I am going to run on June 13. This is part of a series of free virtual workshops I started to offer via the Code Mavens Meetup group. If things go well I'll run workshops for 3 languages: Perl, Python, and Rust and several related technologies. I've already schedule 3 events for Rust, 2 for Python, and 1 for Perl. Now, to plan ahead, I scheduled another Perl event: Continuous Integration (CI): GitHub Actions for Perl…
Read More
Load Testing Solium Infernum with Docker, Kubernetes and Enemy AI

Load Testing Solium Infernum with Docker, Kubernetes and Enemy AI

Load testing a video game is a critical part of the development process if you have any intention of building online systems into your game. As we’ve seen many times before, it's important that you plan for both critical success as well as critical failure when it comes to online multiplayer systems. The results of being over or under prepared can have devastating effects on your players, or your bank account. For Solium Infernum, we had a 4-6 player, turn-based, asynchronous multiplayer game. That last part is important because it means that a game of Solium Infernum can last for…
Read More
Entendiendo la Mutabilidad y la Re-asignación

Entendiendo la Mutabilidad y la Re-asignación

Buenas, hoy quisiera hablar sobre un tema que puede ser confuso al iniciar en programación, especialmente en lenguajes como Javascript donde la diferencia es tan clara: La Mutabilidad y la Re-asignación. Al igual que en otros lenguajes, Javascript permite la definición de variables en las cuales almacenar datos. Existen 3 palabras reservadas que nos sirven para definir variables: var, let y const, pero para este artículo, nos concentraremos en estas últimas 2, y ahondaremos en su relación con la mutabilidad y la reasignación. let: Permite definir una variable cuyo valor puede re-asignarse en cualquier momento. const: Permite definir una variable…
Read More
Webassembly: Near-Native Performance for Web Applications

Webassembly: Near-Native Performance for Web Applications

I was working on a web development project, building a 3D visualizer. This project required a lot of calculations and data processing. I used JavaScript, my go-to language for web development. At first, everything went well. But as I added more features, the website started to slow down. The rendering times increased, and the animations became choppy. It was clear that JavaScript alone wasn't enough for this project. It was slow because JavaScript is an interpreted language and runs on a single thread, meaning it can only do one thing at a time. These performance issues were a big problem,…
Read More
Stacks, Data Structures

Stacks, Data Structures

Stacks A stack is a fundamental data structure in computer science that operates on a Last In, First Out (LIFO) principle. This means that the last element added to the stack is the first one to be removed. Stacks are analogous to a pile of plates where you can only add or remove the top plate. This simplicity and the constraint on how elements are added and removed make stacks particularly useful for certain types of problems and algorithms. Basic Concepts of Stacks Push Operation: This operation adds an element to the top of the stack. If the stack is…
Read More
Linked List, Data Structures

Linked List, Data Structures

Linked List A linked list is a fundamental data structure used in computer science to organize and store data efficiently. Unlike arrays, linked lists consist of nodes, where each node contains data and a reference (or link) to the next node in the sequence. This structure allows for dynamic memory allocation and efficient insertions and deletions, making linked lists highly versatile and useful for various applications. Comparison with Arrays Linked lists and arrays are both used to store collections of elements, but they have key differences that affect their performance and usage: Memory Allocation: Arrays: Use contiguous memory allocation. The…
Read More
No widgets found. Go to Widget page and add the widget in Offcanvas Sidebar Widget Area.