teleren/devto huggingface dataset:
Explaining Angular JS to You Like You're Five.
Tags: beginners, webdev, explainlikeimfive
Published: 2018-05-14 18:17:40

---
title: Explaining Angular JS to You Like You're Five.
published: true
description: One day, you wanted to throw a puppet show.
tags: beginners, webdev, explainlikeimfive
cover_image: https://thepracticaldev.s3.amazonaws.com/i/kqfz6a2zsey6k0c7k2um.jpg
---

I came across [this post](https://dev.to/andrewsmith1996/explain-like-im-five-angularjs-and-when-youd-use-it-82o), which challenged me to wrap my head around the simplest way to explain the basic concepts of Angular JS.

I used Angular JS as the framework for my [final project](http://thearkhives.com) in 2016.
Angular JS is now deprecated, but I still wanted to take a stab at explaining it to a 5 year old.

***

### You throw a puppet show.

But you want to tell different stories with different characters and settings!

You could host each story on separate stages, all with a single set background, and specific puppet set assigned to that stage.

But wouldn't it be exhausting to go to different stages for each story?

### How about telling stories with one stage, with an interchangeable background rig, and a variety of puppets?

You don't have to use a completely different stage and puppet set for each story

* Princess and the Frog? Put up the castle background and bring up the princess and frog puppets.

* Beauty and the Beast? Keep the princess puppet and the castle background, but put away the frog.

* A story with a princess battling a beast in a forest? Change the castle background to the forest.

* Want to tell a story about ducks in the forest?

You get my point.

Instead of having 3 separate stages for 3 different stories, you would have one stage, that can display many types of backgrounds, and frame varying puppets for any story you would like to tell.

***

I don't want my page to waste time and bandwidth to load a whole new page with the same nav bar, same logo, same title. Rather, I'd keep the nav bar, but change the content: add a form, add a gallery, load a video, etc.

***TL;DR***: The nav bar is the stage, the background and puppets are your content. Change the content on one stage.


***

#### So how'd I do? How would you explain it?
Are you worried where your garbage goes?
Tags: garbagecollection, java, runtime, coding
Published: 2018-05-14 16:53:31

---
title: Are you worried where your garbage goes?
published: true
description: Garbage Collection Part 1 of 3.
tags: garbage collection, java, runtime, coding
---

I have started with Java as my programming language and developed many applications in Java only (Ok, sometimes python) for 3 years. It is when I started my first official study in computer science, I realized there is a huge hue and cry about memory management. I started doing my college projects in C/C++, and realized, Uff !! I have to worry where my variables stay in memory and if they are not needed anymore, I have to free up space too. It is strange that till the time we face a problem, we never know that exists and it is handled for us (as Java handles it for us). This intrigued me into taking system classes in my college to get in-depth knowledge about how garbage(i.e. variables not used anymore) is collected in Java and how I coded carefree in Java for 3 years!

![Where is your garbage going ?](https://thepracticaldev.s3.amazonaws.com/i/dim356rgpxvtl3hcazbf.png)


Ok, starting from scratch. You put int x=5. During the runtime i.e. execution of the program, this x is going to point towards a location of 4 bytes on the heap which has 5 as a value. You used this x in one line of your 1000 lines of code and then not use it anymore! What is scary to thing is that these 4 bytes are locked for a variable which is hardly used anymore in your program. Solution: Use lesser variables? Not possible: we know that these high-level programming languages are meant to give us the freedom to use whatever we want! That’s what helped to code and earn a living out of it despite never having any official education in computer science! Another solution: there should be some way that computer (in the very naive way) keep checking for these left /unused bytes in memory and keep deallocating them for us.

There are many algorithms/schemes which are used in mixed and match style to do this automatic cleaning for us. They deviate on various logics. Some of these logics answer the following questions. Ponder upon them before knowing these logics!

1. When to garbage collect? 
   As soon as a variable is not used. 
   When the memory is full i.e. when it is utterly needed to do it!
   Once in a while.

2. Should we stop the allocation when garbage collecting?

3. Should the allocation be done in this way that garbage collecting is more efficient and cleaner?

4. Is there a pattern in the way objects stay alive/ useful?


I will try answering these questions with real implementations in my next blog. Till then Happy garbaging, oops I mean coding!


Orginally posted on : https://medium.com/@ishani.gupta27.ig/
Introduction to Aspose.CAD, Part 6
Tags: csharp, cad, convert
Published: 2018-05-14 16:01:48

---
title: Introduction to Aspose.CAD, Part 6
published: true
description: 
tags: csharp, cad, convert
---


<a href="https://dev.to/nnevod/introduction-to-asposecad-library-361h">Part 1</a>

<a href="https://dev.to/nnevod/introduction-to-asposecad-part-2-2kgf">Part 2</a>

<a href="https://dev.to/nnevod/introduction-to-asposecad-part-3-1mhf">Part 3</a>

<a href="https://dev.to/nnevod/introduction-to-asposecad-part-4-ma8">Part 4</a>

<a href="https://dev.to/nnevod/introduction-to-asposecad-part-5-4ff6">Part 5</a>

<a href="">Aspose.CAD</a> allows one to render a DWG file to raster image with a font other than specified in the file. Here's how to do that:

##Font substitution
Fonts for text in DWG files are specified in style table objects, represented in Aspose.CAD by a <a href="https://apireference.aspose.com/net/cad/aspose.cad.fileformats.cad.cadtables/cadstyletableobject/">CadStyleTableObject</a> class. Collection of these objects are present in <a href="https://apireference.aspose.com/net/cad/aspose.cad.fileformats.cad/cadimage/properties/styles">Styles</a> property of <a href="https://apireference.aspose.com/net/cad/aspose.cad.fileformats.cad/cadimage">CadImage</a> instance. Styles have names, which can be used to differentiate them. There's an example on how to change font used by a class with particular name:

````csharp
using (Aspose.CAD.FileFormats.Cad.CadImage cadImage = (Aspose.CAD.FileFormats.Cad.CadImage)Aspose.CAD.Image.Load(sourceFilePath))
{
    // Iterate over the items of CadStyleDictionary
    foreach (CadStyleTableObject style in cadImage.Styles)
    {
        if (style.StyleName == "Roman")
        {
            // Specify the font for one particular style
            style.PrimaryFontName = "Arial";
        }
    }
}
```


For now, that's all, stay tuned!

For more examples please visit the <a href="https://github.com/aspose-cad">Aspose.CAD GitHub</a> page. There's also <a href="https://twitter.com/Asposecad">Twitter</a> and <a href="https://www.facebook.com/AsposeCAD">Facebook</a> pages for news on Aspose.CAD.
Hi, I'm Shahroze Nawaz, web developer, cloud hosting advisor and community specialist at Cloudways. AMA
Tags: ama, hosting, devops, cloud
Published: 2018-05-14 11:35:36

---
title: Hi, I'm Shahroze Nawaz, web developer, cloud hosting advisor and community specialist at Cloudways. AMA
published: true
description: 
tags: ama, hosting, devops, cloud
cover_image: https://thepracticaldev.s3.amazonaws.com/i/iu4g16854c92q60b8gel.jpg
---

Hey, developers! I'm Shahroze Nawaz, the Community Manager at [Cloudways](https://www.cloudways.com/en/), A managed cloud hosting platform for growing businesses. I've been working in the developer community for advising best cloud hosting solutions like Cloudways which allows developers, Designers, eCommerce store owners, Site owners to launch their websites and applications on six cloud providers including DigitalOcean, Linode, Vultr, Amazon Cloud, Google Cloud and KYUP containers.

You can launch cloud servers on these providers with few clicks and manage all the server settings from Cloudways platform. 

I've been working on few PHP/JS frameworks for educating budding developers with my tutorials and article on the internet and so far appreciated by thousands of people getting massive views. 

Now, I'm here to answer back your questions/confusions regarding hosting solutions for your next web project. Feel free to ask me anything regarding web hosting, development, and Cloudways. :)

You can follow me on Twitter [@_shahroznawaz](https://twitter.com/_shahroznawaz),
GraphCool Continuous Deployment with Bitbucket Pipeline
Tags: graphql, devops
Published: 2018-05-14 10:32:25

---
title: GraphCool Continuous Deployment with Bitbucket Pipeline
published: true
description: Easily and automatically deploy working GraphCool code to a GraphCool cluster using Bitbucket Pipelines.
tags: graphql,devops
---

> This was originally posted on the [GAPLabs Engineering Blog](https://medium.com/gaplabs-engineering/graphcool-continuous-deployment-with-bitbucket-pipelines-cc1788e01c00).

> If you can automate it, you should.

We all try to live by this, but it’s not always easy. Automation is not the easiest thing to do. But it should be. And continuously deploying a GraphCool server with Bitbucket Pipelines is. Because we use Bitbucket everyday, it’s a no-brainer that we’d use Bitbucket Pipelines as our service of choice.

In order to deploy a GraphCool server, we just need to do these steps:

1. Install the GraphCool CLI.
2. Install dependencies.
3. Run `graphcool deploy`.

## bitbucket-pipelines.yml

![Bitbucket Pipelines](https://thepracticaldev.s3.amazonaws.com/i/o0r8khyzsvi41aob13qv.png)

That’s it. Just include this bitbucket-pipelines.yml file in your root directory and push some changes to the master or dev branches. It will then begin the build and deploy. If you think this is confusing, here’s a little breakdown.

### Breakdown

This pipeline uses the `johnpaulada/graphcool` image as its runtime image, which is just a Node image with the GraphCool CLI installed. This takes care of the step 1 above.

After loading the image, it will then start installing the dependencies with Yarn. This takes care of step 2. If the `yarn.lock` or `package.json` have not changed, Pipelines caches the `node_modules` folder, making the installation process faster.

After that, `graphcool deploy` is run, which starts the deployment process. It knows where to deploy it from the `GRAPHCOOL_TARGET` environment variable. If deploying to `dev`, we use the `GRAPHCOOL_TARGET_STAGING` instead. This takes care of step 3.

## Environment Variables

We need the `GRAPHCOOL_TARGET`, `GRAPHCOOL_PLATFORM_TARGET`, and `GRAPHCOOL_TARGET_STAGING` environment variables. You can get the `GRAPHCOOL_TARGET` and `GRAPHCOOL_TARGET_STAGING` from your `.graphcoolrc` file. The `GRAPHCOOL_PLATFORM_TARGET` is in your `~/.graphcoolrc` file.
Lean Software Development
Tags: agile, softwaredevelopment
Published: 2018-07-25 11:01:22

---
title: Lean Software Development
published: true
tags: Agile,Software Development
canonical_url: https://perfectial.com/blog/lean-software-development/
---

In the world of software “revolutions” emerge nearly every month. Each shift in IT, it seems, whether in ways of development or management of software projects, gets labeled a “breakthrough”, which turns the term into a buzzword, stripped of any meaning. However, every once in awhile, important innovations do appear on the web, and it’s hard for them to cut through all the noise to grab your attention.

Therefore, today, we’ll introduce one of them: lean software development – a ground-breaking methodology that has completely reshaped the whole value stream in IT and yet, unfortunately, remained obscure to a lot of entrepreneurs.

## What is Lean Software Development?

![What is Lean Software Development?](https://perfectial.com/production/wp-content/uploads/2017/03/What-is-Lean-Software-Development.svg)

The concept of lean, in general, was pioneered by Toyota, the Japanese automotive giant, as a mean to reduce waste in manufacturing; but soon grew explosively popular and was adapted, among others, to various competencies in IT business.

Lean development as a separate methodology came to us from the book by Tom and Mary Poppendieck and now is expanded upon by the ever-growing body of literature.

Overall, there are **[7 principles to Lean software development](https://perfectial.com/blog/lean-software-development/)**, each aiming to quicken delivery and bring higher value to end-user:

#### 1. Eliminating Waste
#### 2. Building Quality In
#### 3. Amplifying Knowledge
#### 4. Delaying Commitment
#### 5. Delivering Fast
#### 6. Respecting people
#### 7. Optimizing the whole thing

Although lean software development introduces a customer oriented, flexible system to software development, it’s people who actually make it work. Therefore, look for expertise when hiring a team to build your application; professionals, who are committed to a continuous improvement, and qualified enough to embody the core values of Lean methodology – delivering as much value, in the shortest amount of time and in a most efficient way possible.


The post [How Your Business Should Benefit of Lean Software Development](https://perfectial.com/blog/lean-software-development/) appeared first on [Software Development Company Perfectial](https://perfectial.com).
Building mobile search
Tags: discuss
Published: 2018-05-14 08:26:15

---
title: Building mobile search
published: true
description: building mobile search 
tags: #discuss
---

I am building a mobile application which has a search feature. I have not built search functionality yet. I am interested in knowing what are the things I should aware of before starting to build the search feature. 

I thought about using Algolia (Search as a Service) but it is quite expensive even though Algolia provide 10K Records/100K Operations for free. It might be okay at beginning but might not be enough later. 

Please provide your ideas and suggestions.
How did you figure out your field?
Tags: discuss, career
Published: 2018-05-14 00:59:16

---
title: How did you figure out your field?
published: true
description: Asking for....myself 
tags: #discuss #career
---

It's always fun to see awesome projects that other devs made whether it be in web, AI, mobile, etc etc. 90% of the time it's a huge inspiration to beginner devs (like myself), however there's so many cool fields to try and choose from, I want to ask the question:

### How did you end up in your field?/What made you *want* to get into your field? (field defined as, but not limited to, mobile, AI, research, DevOps, server-side, etc.)
Como criar uma aplicação REST API básica com Spark
Tags: spark, java, microservices
Published: 2018-05-14 00:58:41

---
title: Como criar uma aplicação REST API básica com Spark
published: true
description: micro framework spark
tags: spark, java, microservice
---

Através do micro framework Spark é possível criar micro serviços web com grande facilidade, envelopar num jar gordo e botar pra rodar numa micro instância Docker.

### 1. Crie um projeto maven

Configure o arquivo `pom.xml` com as seguintes dependências:

```
<dependencies>
	<dependency>
		<groupId>com.sparkjava</groupId>
		<artifactId>spark-core</artifactId>
		<version>2.7.1</version>
	</dependency>

	<dependency>
		<groupId>org.slf4j</groupId>
		<artifactId>slf4j-simple</artifactId>
		<version>1.7.21</version>
	</dependency>
</dependencies>
```

### 2. Configure a montagem do jar

Construa um jar gordo que contenha todas as dependências do seu projeto, assim você pode rodar sua aplicação de forma independente.

```
<plugin>
	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-assembly-plugin</artifactId>
	<executions>
		<execution>
			<goals>
				<goal>attached</goal>
			</goals>
			<phase>package</phase>
			<configuration>
				<finalName>${project.name}</finalName>
				<descriptorRefs>
					<descriptorRef>jar-with-dependencies</descriptorRef>
				</descriptorRefs>
				<archive>
					<manifest>
						<mainClass>yourgroupid.sparkrest.HelloWorld</mainClass>
					</manifest>
				</archive>
			</configuration>
		</execution>
	</executions>
</plugin>
```

### 3. Crie um endpoint para sua REST API

Crie uma classe chamada `HelloWorld` onde você irá configurar um endpoint que receba requisições `GET` e devolva o texto simples `Hello World`.

```
import static spark.Spark.*;

public class HelloWorld {
	public static void main(String[] args) {
		get("/hello", (req, res) -> "Hello World");
	}
}
```

### 4. Rode sua aplicação

Pra finalizar, execute esse script para compilar sua aplicação

```
$> mvn dependency:resolver
$> mvn verify
$> mvn package
```

Agora execute o jar gordo compilado

```
$> java -jar nomedoprojeto-jar-with-dependencies.jar
```

Faça uma requisição na URL `http://localhost:4567/hello`

```
// Resposta
Hello World
```

### Conclusão

O Spark oferece uma solução de micro serviço para aplicações web REST API com requisições bloqueantes, isto é, uma requisição fica presa numa tread. Portanto, a recomendação é que as aplicações construídas sobre esse framework sejam simples.

Para escalar aplicações que utilizem essa tecnologia é preciso usar uma arquitetura de microserviços com load balancer e criar novas instâncias de acordo com a demanda.
Can We Stop Pretending Planning Software Development Can Be “Certain”?
Tags: culture, agile, programming, career
Published: 2018-05-13 20:59:54

---
title: Can We Stop Pretending Planning Software Development Can Be “Certain”?
published: true
description: Can we just stop pretending that planning software development is certain?
tags: #culture #agile #programming #career
---

If you've developed software for even a few years, you know estimates are basically worthless.

Unless you're estimating old technology, and building something trivial - the company's asking you to commit to something you've never done before.

I've heard the statement before that being an "agile" team or company is only possible if it's accepted from the leadership all the way down to the individual developers in a company.

The hardest part about being agile is that **we still find out we're wrong**, and even more frequently!

The question is: _how do people treat each other when they're wrong_?

Click below for the full interview with Scott Nimrod.

# [📺 Watch the full hour on YouTube](https://www.youtube.com/watch?v=uh6o2UzoGo0&list=PL32pD389V8xs55cCEeus188KL9WoqiwFq&index=1&t=0s)

Or listen as a podcast:
[🎧 Soundcloud](https://soundcloud.com/jayme-edwards-media/scott-nimrod-on-software-consulting-testing-and-career)

<hr/>
[🔔 Subscribe for 90+ videos on healthy software development](https://YouTube.com/c/JaymeEdwardsmedia?sub_confirmation=1)
Be a good person
Tags: person, goods, empathy, work
Published: 2018-05-14 04:27:51

---
title: Be a good person
published: true
tags: person,goods,empathy,work
canonical_url: 
---

![](https://cdn-images-1.medium.com/max/1024/0*Wfyx_439lPdQmtsH.)<figcaption>Photo by <a href="https://unsplash.com/@priscilladupreez?utm_source=medium&amp;utm_medium=referral">Priscilla Du Preez</a> on <a href="https://unsplash.com?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption>

> We sometimes focus so much on becoming better at our profession or career, that we ignore becoming a better person in the process.

Ok, so yeah, I know it’s very important to keep getting better, especially in our times. Many of us might have the mentality of _“If I don’t continually learn, I’ll become obsolete”._

Let me ask you a question, Have you ever met someone who is a total master in whatever they do for a living, but they are a real pain to work with? I’m pretty sure many of us know someone who fits that description, and believe me, that is not the person you’d want to be to other people.

![](https://medium.com/media/6e679674a67e6493c83a0578e4409482/href)

I’m a software developer, and believe me when I say this: I’ve met some really smart and talented people who write software, they could master any programming language you throw at them, but their ability to talk to people, have empathy, and simply be a good person to others and have a positive impact in a group is really low.

So, my advice to you is to simply focus on being a good person, someone people enjoy working with, because your technical knowledge will only get you so far, the rest will depend on the way you treat people and make them feel.

Got any thoughts on this? Have you ever experienced working with someone like this? I’d love to hear your story.
Startup CliX: DynamoDB & React Front-End on GitHub Pages
Tags: pushercontest, javascript, react, aws
Published: 2018-05-13 18:43:21

---
title: Startup CliX: DynamoDB & React Front-End on GitHub Pages
published: true
description: 
tags: pushercontest, javascript, react, aws
series: [pusher contest]
---

Over the course of this weekend I set up a [front-end in React](https://kay-is.github.io/startup-clix/) and added some data storage capabilities with DynamoDB.

## Front-End

I used [create-react-app](https://github.com/facebook/create-react-app) and [Bootstrap](https://getbootstrap.com/) on [GitHub Pages](https://pages.github.com/) to get things going quick.

I'm rather impressed. It was a matter of about 10 minutes to get everything going.

1. Install `create-react-app`
2. Initialize a new React app
3. Modify the generated `package.json` so it fits GitHub Pages
4. Add Bootstrap the HTML template
5. Run the `build` command
6. Remove the `build` directory from `.gitignore`
7. Commit changes
8. Push to GitHub

The `package.json` for GitHub Pages:

```json
{
  "name": "startup-clix",
  "version": "0.1.0",
  "private": true,
  "dependencies": {
    "react": "^16.3.2",
    "react-dom": "^16.3.2",
    "react-scripts": "1.1.4"
  },
  "homepage": "https://kay-is.github.io/startup-clix/front-end/build",
  "scripts": {
    "start": "react-scripts start",
    "move-html": "mv build/index.html ../index.html",
    "build": "react-scripts build && npm run move-html",
    "test": "react-scripts test --env=jsdom",
    "eject": "react-scripts eject"
  }
}
```
I simply added the URL of my `build` directory on GitHub Pages in the `homepage` attribute.

And added a `mv` after the `build` command, so the new `index.html` ends up in the root directory.

This is just a first version and a friend already told me I should do it mobile first, haha.

Well, shouldn't be a big issue, I guess.

## DynamoDB

After I found out about the limitations of [AWS Step Functions](https://aws.amazon.com/de/step-functions/), I had to get a new data storage ready. Luckily [AWS SAM](https://github.com/awslabs/serverless-application-model) allows definition of [simple DynamoDB tables](https://github.com/awslabs/serverless-application-model/blob/develop/versions/2016-10-31.md#awsserverlesssimpletable).

With the [conditional writes](https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/WorkingWithItems.html#WorkingWithItems.ConditionalUpdate) of DynamoDB I can synchronize player requests a bit better. 

The new game thread would run like this:

1. Player joins are stored in a DynamoDB table
2. Start state-machine execution when enough players joined
3. Then send events via Pusher (game:start, game:end, round:start, round:end, etc.) to the clients.
4. Player send their finished products via HTTP to a Lambda function that stores it
5. End of every round a state-machine Lambda function checks if a players lost
6. If one or less players are left, the game finishes, if more players are left, the round is repeated

## Next

Convert the front-end to mobile.

Let users publish their products.

Setup the state-machine right, so the game events are distributed on time.