Tech Rumors
3 subscribers
235K photos
239K links
Download Telegram
dev.to

1. JavaScript for Interviews
This is my first post/blog/article of any sort, so any feedback will be appreciated.

These are my notes which I prepared to revise for JavaScript interviews. Some of the topics are advanced but are a must-know for a intermediate JavaScript developer.

💪 Basics

JavaScript is a dynamically typed language

Data type of variables can be changed during runtime

var justAVariable = 10;
justAVariable = "I am a string now";

/* Does not throw any error */

Variables

Scope
Can be updated?
Can be re…
#javascript #webdev #programming

2. Be pragmatic setting up CI for the RDF::KV
Today I tried to set up CI on GitHub Actions for the RDF::KV Perl module
that I found on CPAN Digger to be lacking CI.

It wasn't supposed to be difficult but I encountered some issues and had to be pragmatic in the setup even if far from ideal.

IMHO it is better to have a working CI that already checks part of what can be checked than to have nothing.

I cloned the Git repository of the package and as it came with a Makefile.PL I ran the usual

perl Makefile.PL

just to see a nasty error:

inc…
#opensource #beginners #perl #devops

3. El humor en sistemas
Si dijera que paso un día sin mirar el lado divertido de mi profesión, les estaría mintiendo. Hoy los voy a meter de lleno en el humor de los programadores y cómo entenderlo.

Hablando con mucha gente por ahí, aprendí algo interesante: La gente se siente más motivada a aprender algo cuando hay humor de por medio.

Si te sentás a una mesa donde todos están haciendo chistes sobre algo, querés integrarte, entenderlo y reírte con ellos. Pero no todo el humor es sencillo de entender a la primera.

Yo…
#productivity #humor
dev.to

1. Day 9: CI for Mojo-UserAgent-Cached and Plack-Middleware-Greylist
Today I can report about two pull-requests for two web-related Perl projects.

One of them is called Mojo-UserAgent-Cached and the other one is Plack-Middleware-Greylist.

Mojo-UserAgent-Cached

It was quite straight-forward. There were only two small issues.
I had to install Module::Install before I could use the regular tools
as the Makefile.PL relies on that. That's a known drawback of Module::Install for developers and maintainers.

The other problem was that tests were failing on Windows s…
#perl #opensource #programming #devops

2. Which PHP Framework Should You Use in 2023?
If you're looking to start a new project or update an existing one, then be sure to check out this explainer and the accompanying video! We'll give you some tips on which PHP framework to use in 2023, based on the needs of your project.

View This On YouTube

Most of the PHP frameworks in this explainer are frameworks I have familiarity with, some recently, some a long time ago. So, I try to be as objective as possible.

What is a PHP framework?

Before we list which are the best PHP framework…
#php #laravel #frameworks #webdev

3. 10 Tips for Success: How to Be a Productive Developer and Student
Being a developer and a student can be a challenging balancing act. On the one hand, you have the demanding work of being a developer, which requires focus, attention to detail, and the ability to solve complex problems. On the other hand, you also have the demanding work of being a student, which requires you to learn new material, complete assignments, and prepare for exams.

With time I learned that to be successful as a developer and a student, it's important to prioritize your tasks and man…
#productivity
dev.to

SPVM 0.9665 is released
SPVM 0.9665 is released.

New Features and Enhancement

Changes

0.9665 2022-12-10
[Internal Compatible Changes]
* Renamed spvm_api_vm.h to spvm_vm.h.
* Renamed spvm_api_vm.c to spvm_vm.c.
* Renamed SPVM_API_VM_call_spvm_method_vm to SPVM_VM_call_spvm_method.
* Added SPVM_API_call_spvm_method_vm.
* Renamed spvm_inline_api.h to spvm_implement.h
* Shared opcodes in vm codes and precompiled codes.
* The CALL_METHOD opcode is separated to the logic of calling method and return the value.
[…
#perl #spvm #language
dev.to

1. A Perl Pattern for Read-Only Configuration Access
Some programs have many subroutines that need access to some read-only configuration. Deciding how to provide access to this configuration in a safe way, that ensures no mutation will take place, is important to the reliability of the program.

The simplest thing to do is to use a global variable. The problem with using a global variable is that you have to be careful to not mutate it, or else your program may behave mysteriously. If you trust yourself not to mess up, then using a global variabl…
#perl

2. Share code between React Native and React Web
This article explains a coexisting of react native and react web apps with similar to monorepo workspaces behavior, but without sharing node_modules dependencies.

All web workspaces remain workspaces, mobile just acts like workspace.

I've had an existing huge web monorepo. Yarn's nohoist setup, or editing metro configuration wasn't working for me because this monorepo contains a lot of dependencies incompatible with react native. But it might work for you and might be a better solution.

TL;…

3. Fixing Class Composition in Tailwind CSS
I’ve been going back and forth on Tailwind CSS for quite a while. On one hand, I loved the utility-first design, on the other - I hated how my HTML, JSX, etc. was getting bloated by the number of class names required to style even a basic button.

At last, Tailwind has won me over, mainly because it gets rid of one of the things I struggle with the most when writing CSS - naming. After all, as if designing good UI/UX wasn’t hard enough, you still have to find a good and architecturally-sound way…
#tailwindcss #webdev #javascript #programming
dev.to

1. Day 16: Moving from Travis-CI to GitHub Actions for Marpa::R2
Marpa::R2 can parse any language whose grammar can be written in BNF. It used Travis-CI, but since Travis-CI discontinued its free offering for Open Source project the project was without CI.

I asked the author if he would be interested in a GitHub Actions configuration.

A warning during build

I tried to build the module locally and run its tests locally, but I encountered some issues:

First I noticed that there are some warning during the build emitted by one of the dependencies. As it tur…
#perl #programming #devops #ci

2. WebRTC vs. WebSocket: Which is best for your app?
WebSocket and WebRTC are key technologies for building modern, low-latency web apps. This blog post explores the differences between the two. We'll cover the following:

What is WebRTC?
What is WebSocket?
What are WebRTC's pros and cons?
What are the advantages and disadvantages of WebSocket?
What are the key differences between WebRTC and WebSocket?
When to use WebRTC?
When to use WebSocket?
When to use WebRTC and WebSockets together?

What is WebRTC?

Web Real-Time Communication (WebRTC) is a…
#webdev #websocket #webrtc
dev.to

1. Transposing a Matrix in Ruby: Using the Zip Method
Have you ever needed to flip the rows and columns of a matrix in your Ruby code? This process, known as transposing a matrix, can be useful in a variety of situations. In this post, we'll learn how to transpose a matrix safely in Ruby using the zip method.

Asking GPT-3 about the Zip Method

There was I solving some Ruby challenges on Exercism.io using when it came to my mind to ask GPT-3 how the #zip method works. I know I could've just googled it or taken a look at the docs, but where is the …
#ruby

2. A recent Perl one-liner on Linux that has Really Helped me as an IT engineer
Recently used Perl one-liner on Linux to replace the strings in SPVM source codes.

This command is dangerous because it does replacement

find * | grep -P '\.(spvm|c|h|xs|y|pm|pod|t)$' | xargs perl -pi -e 's/descriptor/attribute/g'

For Programming Beginners

find * searches all files except for hidden files in the current directory.

| is the pipe.

grep -P '\.(spvm|c|h|xs|y|pm|pod|t)$' extracts files of the specific extensions.

xargs passes each file from the pipe as an argument of the comm…
#perl #linux #beginners #programming

3. Challenge: Display EC2 instances from all regions using Python and Boto3
This was an idea from the AWS Certified Global Community to create challenges by breaking a certain part of code, so the users can learn by fixing the code.

I have written this second challenge for the AWS Certified Global Community and have also used it to mentor some of my mentees.
I thought that it might be a good idea to share this with the broader community as well.

Boto3 is the name of the Python SDK for AWS. It allows you to directly create, update, and delete AWS resources from your Py…
#aws #boto3 #ec2 #lambda
dev.to

1. [OpenTelemetry] Observability of Async Processes with Custom Propagator
It’s the 23rd day of Makuake Advent Calendar 2022 .

As we know OpenTelemetry is an observability framework to generate and export telemetry data. As more companies adopt microservices and SLI/SLOs, we need it to answer new, never-before-seen (and complex) questions.

In that context, observability of systems that communicate using asynchronous messaging is as important as systems communicates using synchronous messagin like HTTP or gRPC.

How about a notification system as an example:

How long…
#opentelemetry #go #observability #microservices

2. My TOP 3 UI Design TIPS for Developers
As a developer, when it comes to build my own application, I always have the tendency to borrow UI design from other websites or simply to work with design created by someone else, like a designer.

I never cared about design concepts such as colors, fonts, typoghraphy, emphasizing techniques, hierarchy patterns etc..

I used to think that Designing and Implementing an UI were 2 separate world that which must be handled from different roles (a designer and a developer).

Well i was wrong.

Rece…
#webdev #design #ux #tutorial

3. How to use PyTorch from Perl?
How to use PyTorch from Perl?

PyTorch supports C++ in addition to Python.

This means Perl can calls all of the C++ functions of PyCharm.

If you use the spvmcc command of SPVM, you can output an executable file that can be used by its copy.

For Programming Beginers

PyTorch is a library for AI using machine learning.

PyTorch supports Python and C++…
#perl #python #cpp #machinelearning
dev.to

1. How to pass the arguments of Makefile.PL using cpanm
The command cpanm --installdeps . to install dependent modules executes perl Makefile.PL.

How to pass the arguments of perl Makefile.PL executed by cpanm.

The answer is using the --configure-args option.

cpanm --installdeps . --configure-args="--meta"

For Programming Beginners

cpanm is a command tool to install Perl modules from CPAN…
#perl #cpanm #beginners #programming

2. Android Compose DataStore Tutorial
Introduction

Hello! 👋

In this tutorial I will be introducing DataStore and how you can implement it into your Android Compose application. 😎

What is DataStore

DataStore is part Android Jetpack.

DataStore is a data storage solution that allows you to store key-value pairs or typed objects with protocol buffers. DataStore uses Kotlin coroutines and Flow to store data asynchronously, consistently and transactionally.

DataStore is ideal for small, simple datasets.

In simple terms it's the …
#android #kotlin #tutorial #beginners

3. 20 Git Commands you (probably) didn't know about
If you've ever browsed the git manual (or run man git), then you'll have noticed there's a whole lot more to git than what most of us use on a daily basis. A lot of these commands are incredibly powerful and can make your life a lot easier (others are a bit niche, but still good to know).

This post outlines 20 of my favourite under-used git features, which you can use to level up your development process, impress your colleagues, help you answer git interview questions, and most importantly - h…
#git
dev.to

1. Responsive web Designs with CSS
Hello everyone, today I'll talk about some often asked questions about responsive web design. Although I won't teach you the complete concept of responsive web design, I will go over some related topics, such as navbars, fonts, pictures, flex and grids, media queries, etc. You will get some insight into how to make responsive design for mobile and tablet devices from it.

Let's get started...

Font Size -

When changing the font size to fit the viewport, especially for large headings that displ…
#html #css #webdev #beginners

2. 2022: Best Year of My Life!
Last 365 days of my life was packed with many ups and downs. It was a roller coaster ride but definitely the best year of my life.

Before 2022, these all were my dreams:

- Joining Amplication💜

I joined the most incredible team working on the goal of making developers life easy. I got a chance to work on many amazing things this year.

Saurav Jain

@sauain

I GOT A REMOTE JOB 🥳After months of creating content on Twitter and contributing to Open-Source, I finally got it. 😍I joined @amplicat
#opensource #career #motivation #devrel

3. Day 24: CI for perl5-MIME-Types
After the heavy-lifting of the previous entry in the Daily CI series this was a very easy task. Looking at CPAN Digger I saw MIME-Types. That sounded like a simple Perl module and indeed adding CI was straight forward.

Pull-request It was already accepted.

Conclusion

There are many projects that are low-hanging fruits where you can add GitHub Actions in a matter of minutes and get the benefits immediately…
#perl #ci #programming #devops
dev.to

1. What is SWR and How Can It Improve Your React Apps?
If you're a developer working with React, you may have heard of a library called SWR (Stale-While-Revalidate). But what exactly is it and how can it benefit your React applications?

What is SWR?

SWR is a lightweight library for handling data fetching in React. It was created by Vercel (formerly known as Zeit) and is designed to make it easy to get data into your React components.

One of the key features of SWR is its ability to "stale-while-revalidate." This means that it will first try to r…
#javascript #react #nextjs #webdev

2. Season 2: The one with The Interview
"I say more dumb things in an interview than most people say in their whole career..."

There are good days. There are bad days. Then there are days where everything goes wrong but yet it ends in the best way possible 😌.

On the morning of the interview, my confidence as well as my anxiety was at its peak 🏔️. Then it all unfolded.

Things that went wrong ☠️ - Internet problems, zoom crashing, joining late and, to make matters worse, the doctor checked on me in the middle of the interview.

Thin…
#myjourney #career #community #tech

3. Set HTTP headers with WWW-Mechanize
Perl has several modules on several levels of abstraction to interact with web sites using HTTP requests. One of the nice modules is WWW::Mechanize that is built on top of LWP::UserAgent. In this example we'll see how to set the header in the HTTP request using WWW::Mechanize.

We'll use the service provided by the httpbin.org web site to see the headers we set.

It has many end-points. We use the one that will send back the header the client sent as its content. It makes it very easy to see wha…
#perl #webdev #programming
dev.to

1. Thank you dev.to!
Hey dev.to community,

I just wanted to say a big thank you to the dev.to team for the gift you sent me over the holidays. I just received it in the mail. The card is awesome (and there is a shiny sticker)!

It was such a cool surprise and it really made my day. I'm so appreciative of the recognition for my contributions over the past year (top author 2022, wow).

Thank you dev.to for the effort and attention that you put towards the authors and contributors, and for all the nice additions you g…
#meta #watercooler #community

2. Jenkins for running scripts!
I have over 30 scripts that are used to pull data and push data between different services. Its critical to know when they fail. Sure you could do this with cron but then I looked around and saw that Jenkins could run scripts, console output log, and emails me on fails.

After you have set up jenkins and set up the email settings.

Create a freestyle project
Built Triggers -> set your time so it runs whenever you want.
Build Steps -> Add Build Step -> Execute Shell
perl

Post Build -> Email Not…
#automation #scripting #jenkins #perl

3. Using FontAwesome Icons with Nuxt 3
FontAwesome provides 2,000+ free icons for use in your projects. Here's how to get started using them in your Nuxt 3 app, including how to improve performance by only importing the icons you need.

This is the same configuration I use in my own website, and you can see the full source code at the GitHub repo here.

Installation

Run the following command to add the vue-fontawesome component.

npm i --save @fortawesome/vue-fontawesome@latest-3

You'll also need to install the icon package(s) you…
#nuxt #fontawesome #icons
dev.to

1. one-liner: read first elements of a huge directory
At a client we have a networked disk with millions of files. I was trying to list the first few files to see what's going on.

ls -l | head takes ages, but here is a Perl one-liner to make it work:

perl -E 'opendir(my $dh, "/huge_dir"); my $c = 0; while (my $d = readdir($dh)) { say $d; exit if ++$c > 3 }'

In a different layout that could be put in a file

use feature 'say';
opendir(my $dh, "/huge_dir");
my $c = 0;
while (my $d = readdir($dh)) {
say $d;
exit if ++$c > 3
}

Explanation:

perl
#perl #programming #devops #beginners

2. Answer: Getting Class Rap2hpoutre LaravelLogViewerServiceProvider not found error in a school management software
answer re: Getting Class Rap2hpoutre LaravelLogViewerServiceProvider not found error in a school management software

Jan 17 '23

0

I had the same error message while running a migration on a laravel project I cloned from GitHub.
error message
I discovered that this file is part of the package rap2hpoutre/laravel-log-viewer
Please go to their download page to download this composer package.
You can also run the command below:
composer…

Open Full Answer…
#laravel #php #composer #webdev

3. Deploying a Laravel App on AWS App Runner
Deploying a containerized app gets easier everyday as cloud providers release new products. One of such products by AWS is AWS App Runner.

AWS App Runner is a fully managed container application service that lets you build, deploy, and run containerized web applications and API services without prior infrastructure or container experience.

Ever want to just deploy an app without the Kubernetes or complex networking overhead? Or have a couple of services to maintain without alot of configuratio…
#laravel #aws #docker #k8s
dev.to

1. Zero byte apple-touch-icon markup
*This is part of a series of pieces about code you can safely remove from the tags of your website.

You can read the rest here: getoutofmyhead.dev*

An apple-touch-icon is an image used on iOS devices when a website is added to the homescreen.

Different iOS devices display icons at different sizes, and so it's common to see something like this:

rel="apple-touch-icon" sizes="152x152" href="https://assets.guim.co.uk/images/favicons/fee5e2d638d1c35f6d501fa397e53329/152x152.png"/>
rel="apple-…
#webdev #performance #webperf #html

2. Perl Weekly #601 - The bad apple
Originally published at Perl Weekly 601

Welcome to the Perl Weekly!

I am ambivalent about writing this and including in the Perl Weekly, but I feel if I don't speak up then how can expect others to do so.

For another perspective on the subject I'd recommend you read this thread by Mohammed Hashim on trust and perspective.

A couple of weeks ago I received an email full of good old antisemitism. It was clearly indicating that it is from one of the readers of the Perl Weekly. It was a tirade of…
#perl #news #programming
dev.to

1. The K-Nearest Neighbors Algorithm for regression and classification
K-nearest neighbors (KNN) is a supervised learning algorithm used for classification and regression. The algorithm works by finding the k closest data points (neighbors) to a given test data point and making a prediction based on their labels/values. The prediction is typically the average (for regression) or the majority class label (for classification) among the k nearest neighbors.

In mathematical terms, KNN is a non-parametric method. Given a training dataset of N labeled points in a d-dime…
#machinelearning #datascience #knn #100daysofdatascience

2. US government agencies' opensource projects
1st OSDC pull request

I have been interested in the US government opensource activities since around 2016, so all my OSDC homework entries of the open source projects are in the governments section.

The most interesting project would be ghidra.

Back in 2018 I was looking for a reverse compiling tool to look at the binary of Dominions 5 (it is a play by email 4X game. lots of fun!). IDA pro is really nice but I do not have the budget to purchase a license.

NSA opensourced ghidra right at th…
#osdc #opensource #perl
dev.to

SPVM now supports object-oriented programming in Perl
SPVM now supports object-oriented programming in Perl. One of the goals of SPVM is to realize...
#perl #spvm
dev.to

SPVM::Math - Mathematical Functions
The Math class of SPVM has methods for mathematical functions. Document SPVM::Math -...
#perl #spvm
dev.to

SPVM::MIME::Base64 - Base64 Encoding/Decoding
The MIME::Base64 class of SPVM has methods for Base64 encoding/decoding. ...
#perl #spvm
dev.to

SPVM::Digest::MD5 - MD5
The Digest::MD5 class of SPVM has methods for MD5. Document SPVM::Digest::MD5 - CPAN ...
#perl #spvm
dev.to

Programming communities?
Back 20 years ago I was the organizer of the local #Perl community. We had in-person meetings with...