teleren/devto huggingface dataset:
Is this really a Tower Defense Game?
Tags: programming, javascript, gamedev, news
Published: 2022-09-28 17:51:18

#  To answer the title - YES, IT IS!

---

## ❓ What is all the noise about?!

Hey y'all, We've started a new project with some friends of mine. We want to document this journey and share our experience, thoughts, learn to write posts and mostly motivate ourself to be more productive xD (you all have been there don't judge xD).

---

## 🧙‍♂️ Who Are The Wizzards?
Long story short, We are 3 friends willing to put some effort into something cool that has a huge potential. We've decided to jump into something new for us and not only that, but also create a game with it. You are probably thinking **"What kind of sorcery is this"**

![What kind of sorcery is this](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0367zxsd1d4hdmu9hf0c.jpg)

Well, it's Javascript, this is why we like to call ourselves sorcerers. I'm pretty sure that everyone who wrote any apps in this language will relate to this.

**By sharing our thoughts with you I will be open to any suggestions/critiques that you can throw at us with much love <3.**

---

#### <u>SO FAR WE WILL BE USING THE FOLLOWING:</u>

---

## 👨‍💻 Back-end Part Of Things.

We will be using **NodeJs**, **Apollo**, **GraphQL** and **Postgresql**, followed by some other cool things like **Redis**, **ELK stack** and much more. We've had some hard times to choose from relational database and non-relational database like **PostgreSQL** and **MongoDB** but we feel that this will be the better choice (We may end up using both in long term, who knows). Right now everything is being containerized with **Docker** containers.

---

## 🚝 About The Game
Probably many of you have played **Warcraft 3** and the many variations of a Tower Defense mode that it has. We're big fans of **Castle Clash**, **Green TD**, **Mafazo TD** and many more. You can expect something along the context of those modes or maybe even cooler? **Would be lovely if you share your favorite TD mod and what do you love about it. We would ❤️ to read about it**

---

## 🧑‍💻 Front-end Part Of Things.
The Front will be structured on top of the **BabylonJS** framework, and all it's great features that will shock your eyes! The game will have some lowpoly graphics (the cover is a spoiler, we got a Unity pack from the store and we are ready to USE IT 😈).
Lot of mobs and other cool stuff.

# 🤝 At the end

We would love to know what kind of stuff you’d like me to share in future posts.

- Different implementations of the functionality by code?
- Database Design?
- Just our thoughts?
- Project structure?
- Game progress?

Or anything else?

🤷 We are also looking for someone with experience in **Blender**, cuz you know, we are wizzards, but our crafting skills are kinda missing, we need someone with similar vision to bloom.
How do you guys create front-end?
Tags: webdev, html, css, programming
Published: 2022-09-28 17:46:49

I am planning to create a web app, and I am going to code the whole backend myself (using Node JS), but I can't figure out how to create the front-end without writing all the HTML.

How do YOU guys create front-end? Do you use a page builder or some other tool, or do you write the whole HTML yourself? because writing the whole HTML yourself seems like a really hectic task.
Guest posting sites provider
Tags: guest, posting, seo
Published: 2022-09-28 17:27:33

Hello, Team

This isha here. I am a Freelance guest posting blogger and provide guest posting services on my high-quality blogs. I have been involved in this sector for 3+year and working with many satisfied clients. If you check my sites you will see high DA and real traffic. I have 1000+websites with good domain authority and Alexa rank
Thanks
Managing SSH keys!!
Tags: ssh, git, github, gitlab
Published: 2022-09-28 17:21:17

It was all sudden. I configured my ssh key and it shows you are not authorised to make any changes!!??



## So what it is? Why this happens??

While trying to figure it out I understood that the ssh agent is confused with the identity file. You can see the permission is denied from the public key. The problem is caused after I added my Gitlab ssh key. Assuming the ssh-agent is confused with my Gitlab and Github ssh keys. When I try to push something, ssh checks for my identity file and it doesn’t know which file to pick!! So it might picked Github ssh key for Gitlab server which caused the error.

## Solution
The problem was identifying the identity file. So I made a config file in .ssh folder for a better understanding.

> vi ~/.ssh/config

```
Host gitlab.com
	PreferredAuthentications publickey
	IdentityFile ~/.ssh/gitlab_key_location
Host github.com
	PreferredAuthentications publickey
	IdentityFile ~/.ssh/github_key_location
```
Now the ssh agent knows where to look for the private key for each hosts.
"str and String in Rust confuses a lot of people in the beginning"
Tags: beginners, rust, strings, cryptopals
Published: 2022-09-28 16:45:54

That what Rusteans said to me, after couple of clumsy conversions between strings and buffers.

When I found [some ambiguity in Cryptopals #25](https://www.reddit.com/user/skaunov/comments/xpvxx6/nonce_in_cryptopals_25/?utm_source=share&utm_medium=web2x&context=3), I started to look around for different approaches people employed to tackle it.

Also, after considerable hesitation, I started to use Rust, being completely new to it. As Cryptopals put it in they own words: "Our friend Maciej says these challenges are a good way to learn a new language, so maybe now's the time to pick up Clojure or Rust." Why not?

I thought so, until I finally verified my understanding, that both kind of strings in Rust... *must* be UTF-8 compliant, and won't hold any gibberish. So, strictly speaking part of the challenges become impossible for us, ordinary mortals, when done following description. And part become significantly more difficult, narrowing the space for solutions. So, formally learning Rust with Cryptopals can bring you _nightmare_ side-quests.

This thing with strings, I feel like I like it atm. It's a reasonable type to receive plaintexts, and Rust instantly makes attacks much harder to implement by limiting input with validation. And for exercises we use buffers, of course. Who don't!
Join us for Hacktoberfest 2022 by contributing to StepZen
Tags: hacktoberfest, graphql
Published: 2022-09-28 16:45:26

Hacktoberfest 2022 is about to start! Join us for the latest edition of Hacktoberfest by contributing to StepZen. We're looking for contributors to help us create new integrations and improve existing ones. Contributors will receive limited StepZen goodies and Hacktoberfest swag.

Hacktoberfest 2022
------------------

Hacktoberfest is a celebration of open-source software. It's a month-long event that takes place every October. The goal of Hacktoberfest is to encourage developers to contribute to open-source projects. Hacktoberfest is open to everyone in our global community. You can sign up anytime between September 26 and October 31 via the [Hacktoberfest website](https://hacktoberfest.com/).

Everyone that signs up for Hacktoberfest [here](https://hacktoberfest.com/auth/) has to make four pull requests (PRs) to public repositories on GitHub (or Gitlab). You can make pull requests to any public repository on GitHub with issues labeled `hacktoberfest`. Once approved and merged by the repository maintainers, your pull requests count towards your Hacktoberfest goals.

If you complete four pull requests in October, you'll receive a free Hacktoberfest t-shirt and a limited edition Hacktoberfest 2022 sticker pack. You can find more information about Hacktoberfest on the [Hacktoberfest website](https://hacktoberfest.digitalocean.com/).

Contribute to StepZen
---------------------

StepZen is participating in Hacktoberfest, and you can contribute by adding a new integration or improving an existing integration in our [Examples repository](https://github.com/stepzen-dev/examples). Every PR to this repository will count towards your Hacktoberfest goals.

In this repository, you'll find two things:

*   Examples of how to use StepZen to build a GraphQL API by integrating with databases or external APIs.
*   Usage of a StepZen API in a (frontend) application.

We're looking for contributors to help us create new integrations and improve existing ones. You can find a list of integrations that we're looking for in the [issues](https://github.com/stepzen-dev/examples/issues) for the repository, including a list of improvements to existing integrations. But we encourage you also to open a new issue and PR for other integrations.

> Next to being eligible for the official Hacktoberfest, we'll ship StepZen goodies to contributors. Read the [contributing guidelines](https://github.com/stepzen-dev/examples/blob/main/CONTRIBUTING.md) before creating a PR.

Keep an eye out for new features and more integrations on our [Twitter](https://twitter.com/stepzen_dev) page and [Discord](https://discord.gg/9k2VdPn2FR) community.
Response to preflight request doesn't pass access control check: The 'Access-Control-Allow-Origin'
Published: 2022-09-28 16:42:38

Hello 

## Searching everywhere for my problem, I cannot find any solution 

### my problem
#### i added cors package in main file

##### index.js

```
const cors = require('cors');

const corsOptions = {
    origin: 'https://backend.com/',
    optionsSuccessStatus: 200,
    credentials: true
    
}

app.use(cors(corsOptions));

//  prelight cors error
app.options('*', cors(corsOptions));


app.use((req,res,next)=>{
    res.setHeader('Access-Control-Allow-Origin', '*');
    res.setHeader('Access-Control-Allow-Methods', 'GET, POST, PUT, PATCH, DELETE, OPTIONS');
    res.setHeader('Access-Control-Allow-Headers', 'Content-Type, Authorization');

    next();
})

```
### front=end file post request

```
 axios.post('https://backend.com/blog', {
      method: 'POST',
      headers: { 
        'Content-Type': 'application/json'

      },
      body: JSON.stringify(sendData)
    })
```
## i set origin value = *
Beacuse my Backend file running port = 3001  
Front-end file running on port = 3000

## what error i getting

** Access to XMLHttpRequest at 'https://backend.com/blog' from origin 'https://portfolio.netlify.app' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: The 'Access-Control-Allow-Origin' header has a value 'https://backend.com/' that is not equal to the supplied origin.`
 **

Note : - Urls in above line are not real so don't serch these website on google
Update: Lifecycle events for Amazon ECS are now available in Amazon CloudWatch Container Insights
Tags: aws, cloud, operations, devops
Published: 2022-09-28 16:39:41

Amazon CloudWatch Container Insights now includes Amazon Elastic Container Service lifecycle events (ECS). You can monitor, isolate, and diagnose containerized applications running on ECS using Container Insights. Now that lifecycle events have been added, you can easily correlate metrics, logs, and events in a single view for more complete operational visibility.

Container instance state change events, task state change events, and service action events are among the events. They are automatically sent to Amazon EventBridge by Amazon ECS and are also collected in CloudWatch in event log format. see [Amazon ECS events](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs_cwe_events.html).

Lifecycle events don't incur extra costs. Standard Container Insights pricing applies. see [Amazon CloudWatch Pricing](https://aws.amazon.com/cloudwatch/pricing/)

To configure the table of lifecycle events and create rules for a cluster, you must have the `events:PutRule`, `events:PutTargets`, and `logs:CreateLogGroup` permissions.

To view the table of lifecycle events, you must have the `events:DescribeRule`, `events:ListTargetsByRule`, and `logs:DescribeLogGroups` permissions.

**To view Amazon ECS lifecycle events in the CloudWatch Container Insights console**

1. Open the CloudWatch console at [https://ap-southeast-1.console.aws.amazon.com/cloudwatch/home?region=ap-southeast-1#home:](https://console.aws.amazon.com/cloudwatch/)
2. Choose **Insights, Container Insights**.
3. In the drop-down box near the top of the page, choose **Performance monitoring**.
4. In the next drop-down, choose either **ECS Clusters**, **ECS Services**, or **ECS Tasks**.

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

5. If you choose **ECS Services** or **ECS Tasks** in the previous step, choose the Lifecycle events tab.
6. At the bottom of the page, if you see Configure lifecycle events, choose it to create EventBridge rules for your cluster.
The events are displayed below the container insights panes and above the Application Insights section. To run extra analytics and create additional visualizations on these events, choose View in Logs Insights in the Lifecycle Events table.
DevRel tips for Hacktoberfest
Tags: devrel, speaking
Published: 2022-12-01 19:01:33

---
title: DevRel tips for Hacktoberfest
published: true
date: 2022-09-28 16:35:47 UTC
tags: DevRel,Speaking
canonical_url: https://courtneyr.dev/2022/09/28/devrel-tips-for-hacktoberfest/
---

![sAjrcKufge0 jpg](https://courtneyr.dev/wp-content/uploads/2022/10/sAjrcKufge0-jpg.webp "DevRel tips for Hacktoberfest 34")

![sAjrcKufge0 jpg](https://courtneyr.dev/wp-content/uploads/2022/10/sAjrcKufge0-jpg.webp "DevRel tips for Hacktoberfest 33")

<!-- wp:embed {"url":"https://youtu.be/sAjrcKufge0","type":"video","providerNameSlug":"youtube","responsive":true,"align":"wide","className":"wp-embed-aspect-16-9 wp-has-aspect-ratio"} -->

https://youtu.be/sAjrcKufge0

<!-- /wp:embed -->

<!-- wp:embed {"url":"https://developerrelations.com/podcast/devrel-tips-for-hacktoberfest","type":"wp-embed","providerNameSlug":"developerrelations-com"} -->

https://developerrelations.com/podcast/devrel-tips-for-hacktoberfest

<!-- /wp:embed -->

This article first appeared on:  
 ![](https://courtneyr.dev/wp-content/uploads/2022/10/sAjrcKufge0.jpg)  
[Courtney Robertson -](https://courtneyr.dev)  
by [<span class='p-author h-card'>Courtney Robertson</span>](https://courtneyr.dev/author/courane01/)
TL;DR: Move CI/CD scripts into .automation
Tags: devops, productivity, tutorial, tooling
Published: 2022-09-28 16:13:54

Today our `/bin` folder has become overwhelmed with different development tools and scripts.

We put everything there: local automations, _CI/CD_ helpers, _PAAS_ release scripts, `Dockerfile` helpers, etc.

It becomes too hard to find appropriate tools for your problem in that mess. 

![Messy bin folder](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/byrgpl5ltann5d4ism3e.png)

I had several revisions on decomposing the `/bin` scripts and the whole directory, but I still have not found one solution.

I have played with subfolders `/bin/heorku/release` and prefixes `/bin/ci-setup`. Each strategy has pros & cons. 

## CI/CD is on the way out

But I have found that developers do not use _CI/CD_ scripts locally, which means we could move them out from the `/bin`.

Exploring some _GitHub Actions_ documentation, I found this neat folder: `/.automation`. And I got that this what I have looked.

`/.automation` is an excellent place to hide some ninja scripts which developers would not like to read or maintain.

So, all my last `bin/ci-setup` will become: `.automation/tests/setup`. Or if I need to put composed steps for _GitHub Actions_, I'll have `.automation/actions/prepare.yml`

### References:

Here is a good example: https://github.com/github/super-linter/tree/main/.automation

---

**Paul Keen** is an Open Source Contributor and a Chief Technology Officer at [JetThoughts](https://www.jetthoughts.com). Follow him on [LinkedIn](https://www.linkedin.com/in/paul-keen/) or [GitHub](https://github.com/pftg).
> If you enjoyed this story, we recommend reading our latest tech stories and trending [tech stories](https://jtway.co/trending).
Angular Structural directives Start With *
Tags: angular, webdev, beginners
Published: 2022-09-28 16:11:43

Briefly speaking, [Angular has 3 types of directives](https://angular.io/guide/built-in-directives):
1. **Components**
2. **Attribute directives** - Change the style or behavior of an element, component, or another directive. You may know NgClass, NgStyle, and NgModel.
3. **Structural directives** - Manipulate the DOM layout by adding and removing DOM elements. You may know *ngIf, *ngFor, *ngSwitch.


Only structural directives are prepended by an asterisk (*).


Structural directives wrap the element in an `ng-template` element, that adds and removes its content from the [Document Object Model (DOM)](https://medium.com/p/c95531731367). 

### Main difference between structural and attribute directives
The main difference between structural and attribute directives is that the former changes the structure of the DOM by adding and removing content. 
The latter only hides or shows content in the UI but the content is always available in the DOM.

Use the [dev tool to see the DOM tree](https://medium.com/p/c95531731367) and how it changes when you use either of them. 

### Pros & Cons
Often you will just use either structural or attribute directives for a specific scope.

However, when you can choose, you should be aware of the advantages and disadvantages of the two directives.

Broadly speaking, attribute directives are less performance-intensive when they hide and show elements. However, behind the scene, they always create the DOM branch of the elements they should render or hide.

On the other side, structural directives don't always create a DOM branch. This might decrease resources need in the beginning. However, they might be less efficient when an element changes often because the element gets destroyed and re-created in the DOM.
Adrian Bridgwater (ComputerWeekly.com) recently wrote an article about how Luos plugs microservices in IoT
Tags: opensource, microservices, iot, luos
Published: 2022-09-28 16:02:20

⏩ https://www.computerweekly.com/blog/Open-Source-Insider/Luos-plugs-microservices-into-IoT

💬 “Adding support for the ESP32 makes Luos compatible with IoT product development happening around the world.” said Nicolas Rabault

Many thanks to Adrian for this article.

![Luos plugs microservices in IoT](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/okodf0l2inx9d3c7mghm.jpg)
Steve Jobs Isn't Remembered For A Programming Language
Published: 2022-09-28 15:51:04

## Focus On Solutions, Not Technology
As Software Developers we often get lost in the beauty of a programming language.  No matter which language you use (JavaScript, Python, C#) you probably fall in love with it a little bit.  The better you get at using the language the more you fall in love with it.

### Users Don't Care Which Language Your Solution Is Written In
But, users don't care which language your solution is written in.

## Steve Jobs == Objective-C ?
No one remembers Steve Jobs because his company, Next, created Objective-C.  They remember him because help create an elegant product which everyone wants to use (iPhone).

## The iPod & Music
Before the iPhone Steve Jobs was in love with another product.  It was something he wanted.  It was a portable music player that **Steve himself wanted to use**.

Steve wanted a cool device that would allow him to listen to any / all of his music no matter where he was.  
Tens of millions of other people wanted this solution also.


![original ipod](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/skx85hj2sb3v4fb640vz.png)

## As A Software Developer
As Software Developers we often get all caught up in technologies & the _best_ programming language and pedantic details of technology.  Users don't care about any of that.

### Users Want Easy Solutions
Users just want solutions to their daily challenges which are easy to use and work properly.   

### Think From User's Perspective
If we change our thinking towards what a user really wants:
1. easy to use solution
2. works properly
3. low cost (lowest possible)

then we can begin to see behind the reasons that they want the thing they are requesting.  If we become users of our own software we will discover that we want it to be easier to use -- no confusing UI and our solutions will become far better.

So the next time you're arguing about which language is better just remember the best language is the one that helps you create a solution that:
1. creates an easy to use solution (easily deployed to users)
2. works properly -- doesn't confuse the user, use it yourself
3. is the right price

## To Get There
You'll have to understand much more than just programming languages to create a great product.
You'll need to understand:
1. what the user wants
2. how to make it easier for the user
3. how the business works 
4. how to deploy it so the user can get the product
5. COGS (Cost of Goods Sold) -- how much does it cost you to create it?

You'll learn far more from creating a usable solution than just learning a new programming language.
Inheritance C++ Example 1
Tags: cpp, oop
Published: 2022-09-28 15:43:03

Easy way to understand oops is to code it, run it, debug it. Repeat it till you get something new every iteration.

The below program is self explanatory and easy to understand.

_Leave comment if you find hard to understand and I will be there to help (Let me know what error you get)_

Follow step by step, first code for Person class and create person object and see is it working fine and then for Student class. At the end inherit Person as public to Student.

```
#include <bits/stdc++.h>
using namespace std;

class Person{

    int id;
    char name[20];

    public:
        void setP(){
            cout<<"Enter Id: "; cin>>id;
            cout<<"Enter name: "; cin>>name;
        }

        void displayP(){
            cout<<"Id: "<<id<<"\tName:"<<name<<endl;
        }
};

class Student: public Person{

    char course[20];
    int fee;

    public:
        void setS(){
            cout<<"Enter course: "; cin>>course;
            cout<<"Enter fee: "; cin>>fee;
        }

        void displayS(){
            cout<<"Course is: "<<course<<"\tfee: "<<fee<<endl;
        }
};


int main(){

//Inherit person class behaviour in student class
    Student s;
    s.setP();
    s.setS();
    s.displayP();
    s.displayS();


    return 0;
}
```

Now inhert Person class privately to Student class
_Before looking to code try once_

```
class Student: private Person{

    char course[20];
    int fee;

    public:
        void setS(){
            setP();
            cout<<"Enter course: "; cin>>course;
            cout<<"Enter fee: "; cin>>fee;
        }

        void displayS(){
            displayP();
            cout<<"Course is: "<<course<<"\tfee: "<<fee<<endl;
        }
};


int main(){
    Student s;
    s.setS();
    s.displayS();

    return 0;
}
```
Crux: _Publicly inherited class are accessible to  child class object and it's member function. But when class is privately inherited it can be accessed only through child class member functions._