teleren/devto huggingface dataset:
Announcing Jupiter Release 0.5.1
Tags: jupiter, post
Published: 2020-10-19 07:18:30

---
title: Announcing Jupiter Release 0.5.1
published: true
date: 2020-10-18 00:00:00 UTC
tags: jupiter,post
canonical_url: https://horia141.com/announcing-jupiter-0.5.1.html
series: "Jupiter Dev Log"
---

I’ve prepared a minor release - `0.5.1` - which contains a lot of goodies for recurring tasks. This version introduces:

- Recurring tasks can have _active intervals_. Only during this interval will inbox tasks be generated. This can be open ended of course.
- Inbox tasks from recurring tasks now have the year included in the name.
- Reporting on habits also shows a “completion ratio” broken down by sub-periods.
- Inbox tasks now have an _actionable date_. They’ll be visible to work on one week before this. Recurring tasks have been updated to allow generation of such fields too.
- Fix a timezone issue with recurring tasks generation.
- Fix an issue with smart list syncing which caused every smart list to contain every smart list item.

As always checkout the [installation instructions](https://jupiter-goals.readthedocs.io/en/stable/install/) to find out how to get hold of the latest version.
Remove element from DOM in React way
Tags: react, webdev, discuss, javascript
Published: 2020-10-17 23:49:01

{% codesandbox 44g3n %}

We will be using `useEffect` Hook to execute [JavaScript](https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setTimeout) `Window.setTimeout()` function which will help hide an element in the DOM (a side effect).

From [React](https://reactjs.org/docs/hooks-effect.html) docs,
> Data fetching, setting up a subscription, and manually changing the DOM in React components are all examples of side effects.

In the `setTimeout` function, set the state variable `visible` to `false` after some amount of `delay`, which comes from `props`. In this example, `5000` milliseconds. In other words, we are telling `setTimeout` function to set the `visible` variable to `false` after 5 seconds.

```jsx
import React, { useEffect, useState } from "react";

const Expire = props => {
  const [visible, setVisible] = useState(true);

  useEffect(() => {
    setTimeout(() => {
      setVisible(false);
    }, props.delay);
  }, [props.delay]);

  return visible ? <div>{props.children}</div> : <div />;
};

export default Expire;
```

You might have thought what is the optional second argument, `props.delay` doing in the `useEffect` Hook. By doing that, we told React to skip applying an effect if certain values haven’t changed between re-renders. This is for [performance optimization by skipping effects](https://reactjs.org/docs/hooks-effect.html#tip-optimizing-performance-by-skipping-effects) :bulb:. 

Let's say you forgot you mention the second argument, you would notice that the app will cause unnecessary re-renders even after the element is hidden from DOM and thus affecting your app performance.

```jsx
useEffect(() => {
  setTimeout(() => {
    setVisible(false);
  }, props.delay);
}); // This causes re-rendering effect
```

Now that we are done with our functional component, let's bring it to [action](https://codesandbox.io/s/hide-element-from-dom-react-way-44g3n?from-embed) altogether :rocket:. Pass in delay props (`5000` milliseconds) to our `Expire` component and you will notice that the element would be hidden from the DOM after `5` seconds.

```jsx
<Expire delay="5000">Hooks are awesome!</Expire>
```
Is Rails Still a Thing in 2020?
Tags: rails, development
Published: 2020-10-18 00:36:31

---
title: Is Rails Still a Thing in 2020?
published: true
date: 2020-10-17 23:47:25 UTC
tags: rubyonrails,development,rails
canonical_url: https://medium.com/@kelsiproulx1919/is-rails-still-a-thing-in-2020-632224a1b22c
---

[![](https://cdn-images-1.medium.com/max/800/0*v06d7Yx8MpFAa8oc)](https://medium.com/@kelsiproulx1919/is-rails-still-a-thing-in-2020-632224a1b22c?source=rss-113ed2019dc2------2)

In 2008, Twitter migrated from a Ruby on Rails (RoR) backend framework to Scala, claiming issues of scalability. This occurred 12 years…

[Continue reading on Medium »](https://medium.com/@kelsiproulx1919/is-rails-still-a-thing-in-2020-632224a1b22c?source=rss-113ed2019dc2------2)
Interview Feedback Antipatterns
Tags: career, interview, discuss
Published: 2020-10-17 23:33:05

One of the more valuable training exercises I've had in my career was a slide deck on interview feedback. It reinforced two points that I try to keep in mind when conducting interviews and giving interview feedback:

* My goal when interviewing is to evaluate the person for the job I'm interviewing them for.
* My feedback and conclusions should relate specifically to the job the candidate is interviewing for.

A lot of common interview feedback (often negative feedback) doesn't do this, being either generally vague or specific but not obviously related to the position. 

When I see these types of statements in my own feedback, it's a cue to think more carefully about the candidate. Often my point can be made more precise; this helps make for a more productive interview feedback session. Sometimes vague sentiments or gut feelings vanish under closer examination; when this happens, I learn something important about my blind spots and biases.

I also try to keep this in mind when listening to the feedback of others during candidate sync ups. If I hear a negative appraisal of a candidate without specific, clearly relevant justification, it's a cue to ask follow up questions.

Some examples that come to mind for me (having seen/heard them fairly commonly): [^1]

* Many points about communication skills. [^2]
* Lack of "passion" / lack of growth mentality. [^3]
* Many things related to culture fit. [^4]
* Whether the candidate seems excited about the position. [^5]

I would love to read about how other developers handle this. Do you have particular types of feedback you take as a cue to go back and think more about a candidate, or ask other people to do so? Do you have an engineering culture where you feel empowered to do this?

[^1]: I don't mean to imply that these are always invalid things to consider in feedback. Only that they are frequently (in my experience) raised as self-evident reasons to pass on a candidate, without specifics and without reflection about whether they are actually relevant for the job.
[^2]: "Poor communication skills" is not great feedback. "The candidate was not able to clearly articulate the service boundaries of his design in our panel; he would be expected to do this as a principal engineer here" is better; it provides more specifics, and explains why this concern is relevant.
[^3]: Often, in my experience, raised for more senior, older, or non-traditional candidates who don't have a bunch of GitHub repositories showing off side projects and the like. Does not by itself say anything about how well the candidate would work as an employee.
[^4]: Self-evident, I hope.
[^5]: A great many developers manage to be good at their jobs without being excited about them. Some developers may be excited without reading that way (e.g., they're quieter, mellower). It is also really easy to fake being excited. This just doesn't seem like a great thing to look at.
Caching in Spring
Tags: cache, spring, java
Published: 2020-10-17 20:58:52

When you have a method that always returns the same result for the same arguments (calculations, queries, requests, etc.), you can implement caching. You just need to mark the method as cacheable:

```java
@Cacheable("books")
public Book findBook(String refId) {...}
```

Its result is stored in a cache and the subsequent invocations (with the same arguments) will fetch the data from the cache using the key, and the method will not be executed.

The @Cacheable annotation has two main attributes, the value (name of the cache) and the key (for each cached data-item). In the previous example, we used a default key. Let's see an example with a custom key, where we can use SpEL (see [Spring Expression Language](https://dev.to/eidher/spring-expression-language-spel-32fa)) and arguments of method:

```java
@Cacheable(value="books", key="#refId.toUpperCase()")
public Book findBook(String refId) {...}

// Only cache if condition is true
@Cacheable(value="books", key="#title", condition="#title.length < 10")
public Book findBook(String title, boolean checkWarehouse) {...}

// Using an object property
@Cacheable(value="books", key="#isbn.rawNumber")
public Book findBook(ISBN isbn, boolean checkWarehouse) {...}
```

Caching must be enabled using the @EnableCaching annotation in the configuration class (see [Spring Configuration](https://dev.to/eidher/dependency-injection-using-spring-ckk))

See [https://docs.spring.io/spring-framework/docs/current/spring-framework-reference/integration.html#cache](https://docs.spring.io/spring-framework/docs/current/spring-framework-reference/integration.html#cache)
Store in Svelte
Tags: svelte, javascript
Published: 2020-10-17 23:00:44

---
title: Store in Svelte
published: true
description: It's very simple!
tags: Svelte, javascript
//cover_image: https://direct_url_to_image.jpg
---

store.js

```javascript
import {writable} from "svelte/store"
export const apple = writable(5)
```

Get store

```html
<p>I have {$apple} apples</p>
<script>
 import {apple} from "./store.js"
</script>
```

Change store

```javascript
import {apple} from "./store.js"
$apple = 10
```

or

```javascript
import {apple} from "./store.js"
$apple = $apple + 1
```
HacktoberFest 2020
Tags: hacktoberfest
Published: 2020-10-17 22:59:58

## What I Learned From Hacktoberfest

Hey folks!

Here I'm going to share my experience with hacktoberfest 2020. Okay, I'll start from the beginning where I heard about hacktoberfest at first. My first impression of hacktoberfest happened at the ''Open Hack Day event 2019'' at NSBM Green University. That was the first time I participated in an open-source event. In that event  I got the opportunity and guidance on how to contribute to open-source, how to work with Git/GitHub. 

During the event, I was able to figure out how to participate to hacktoberfest. So the best part of the story is, that I couldn't make the pull requests on-site because I didn't take a laptop with me. That gave me a big motivation to go home and study about this Newly heard month-long open-source celebration. 

Somehow within a week, I learned git/GitHub which is really amazing, and made my 4 pull requests to participate in the hacktoberfest 2019. After that, I was so curious about this opensource thing. So I decided to continue. And I was waiting for the Hacktoberfest2020 event. 

oh! It's here.. for today, I've completed the hacktoberfest2020 challenge and claimed the swag also. It was so nice to collaborate with new projects and other developers all around the world. This time I was focus on web-based projects written using mostly javascript. And I contributed some other C# projects as well.

So Freshers, If you are looking for an opportunity to bump into open-source, Hacktoberfest is the ideal place to start off with. Trust me this Hacktoberfest thing changed my life. It was a huge turning point in my life as a fresh undergraduate at that time.

So guys contribute and make an impact to make the techno world a better one. I'll put links to some tutorials that I took when I bumped into open-source below.

Github learning lab: https://lab.github.com/

Git/Github Tutorial by NetNinja youtube channel :
https://youtu.be/3RjQznt-8kE

Github Documentation: https://docs.github.com/en

#####OpenSource | GitHub | Git | HacktoberFest | hacktoberfest2020
He exclaimed join hacktoberfest
Tags: hacktoberfest
Published: 2020-10-17 22:41:46

<a href="https://dev.to/r1dwanmaulana">
  <img src="https://d2fltix0v2e0sb.cloudfront.net/dev-badge.svg" alt="R1dwanMaulana's DEV Profile" height="30" width="30">
</a>

## What I Learned From Hacktoberfest

Since mid-2020, I just learned about the annual event from digital ocean, namely *hacktoberfest*. Where all developers contribute to each other. The lesson that can be taken while participating in hacktoberfest is that we have experience, and can learn more about git, as long as it benefits other people or other developers. the first time I was interested in joining Hacktoberfest and I registered myself and I planned to contribute with Microsoft, 14 days passed during the collaboration process I finally won the challenge from Hacktoberfest, this is really extraordinary, and my interest is strong for the upcoming Hacktoberfest event. Thank you, and happy hacktoberfest.🎉
My First Hacktoberfest
Tags: hacktoberfest
Published: 2020-10-17 22:33:07

Since I decided to change my career in 2019, I spend most of my time looking for courses, articles, and knowledge. This year I got to know the Women Who Code community in Recife and, alongside wonderful women, I participated in my first hacktoberfest. Contributing to a project and submitting my first pull requests was an incredible experience.
Hoisting in JavaScript
Tags: javascript
Published: 2020-10-17 22:19:58

### What is Hoisting?

In JavaScript, **hoisting** is the terminology used to describe how a variable or function can be used before it has been declared.

##### Example:

```javascript
console.log(name) // => undefined
var name = 'Pharia'

```

Conceptually we can imagine that the binding name is _hoisted_ to the top of the code.

```javascript
var name // declaration is moved to the top
console.log(name) // => undefined because all variables in JS are initially set to undefined
name = 'Pharia' // assignment is not moved

```

### How is this possible?
In JavaScript, before code is executed line by line, the JS Engine will set aside memory space for the variables that you've created in that entire code you've built and all the functions you created as well. This is considered the compilation phase which will be followed by the execution phase.

* for variables, only variables declared with the keyword var can be hoisted
* for functions, a functions name identifier and body are all hoisted

##### Examples

#### var - CAN hoist

```jsx
console.log(name) // undefined
var name = "Pharia"
```

#### const - CANNOT hoist

```jsx
console.log(name) // // ReferenceError: Cannot access 'name' before initialization
const name = "Pharia"
```

#### let - CANNOT hoist

```jsx
console.log(name) // ReferenceError: Cannot access 'name' before initialization
let name
```

#### variable declared with no keyword - CANNOT hoist

```jsx
console.log(name) // ReferenceError: name is not defined
name = "Pharia"
```

#### function - CAN hoist
```jsx
logName() // => "Pharia"
function logName() {
  return "Pharia"
}
```

### Conclusion
Although hoisting is possible in Javascript, is it better practice to declare all your functions and variables at the top of their scope to avoid bugs &/or errors.

& Remember... Happy coding, friends! =)

###### Sources
* https://developer.mozilla.org/en-US/docs/Glossary/Hoisting
* https://www.youtube.com/watch?v=Bv_5Zv5c-Ts&feature=emb_title&ab_channel=TonyAlicea
Linting Jinja Templates using Sparrow plugin jinjalint
Tags: raku, python, jinja, automation
Published: 2020-10-17 21:09:48

---
title: Linting Jinja Templates using Sparrow plugin jinjalint
published: true
description: How to lint jinja templates using Sparrow 
tags: Raku, Python, Jinja, Automation
//cover_image: https://direct_url_to_image.jpg
---

Meet new Sparrow plugin [jinjalint](http://sparrowhub.io/plugin/jinjalint/0.000001) to lint jinja templates. 

---

Let's get started!

## Setup a tom task

```bash
$ tom --edit jinja-lint
```

```raku
task-run "lint my code", "jinjalint", %(
  args => [
    "templates/",
    ["verbose"]
  ]
);
```

## Put some templates to check into `templates/` directories

```bash
$ mkdir templates/
```

## Run check

```bash
$ tom jinja-lint
21:03:50 10/17/2020 [repository] index updated from file:///home/ubuntu/repo/api/v1/index
21:03:51 10/17/2020 [lint my code] run [jinjalint templates/ --verbose] ...
21:03:51 10/17/2020 [lint my code] Files being analyzed:
21:03:51 10/17/2020 [lint my code] templates/template.html
21:03:51 10/17/2020 [lint my code]
21:03:51 10/17/2020 [lint my code] templates/template.html:3:5: Parse error: expected one of '[:a-z]', 'area', 'base', 'br', 'col', 'command', 'embed', 'hr', 'img', 'input', 'keygen', 'link', 'meta', 'param', 'script', 'source', 'style', 'track', 'wbr', '{#', '{%', '{{' at 2:5
21:03:51 10/17/2020 [lint my code] task exit status: 1
21:03:51 10/17/2020 [lint my code] task lint my code FAILED
```

That is it! You no longer miss errors in your jinja templates.

---

Check updates on [SparrowHub.io](http://sparrowhub.io) - universal automation repository.

---

Aleksei
An Open Source Physics Simulations Project!
Tags: hacktoberfest, opensource, contributorswanted, javascript
Published: 2020-10-17 21:04:47

## What is "The Physics Hub"?

Please take your time and check out the project here: https://physicshub.herokuapp.com/

The Physics Hub is an open source physics simulations project that aims to provide clear and understandable physics simulations free for everyone!

I have assembled a team of physics students from Reddit and started the project nearly three months ago. Our community have continuously grown since we started. We have used p5.js to create the simulations so that we could run them on a website. Anyone interested in the project can always go to our Github repository and take up or create issues. We have an open Discord server where we discuss things about the project as well.

You can find our Github repository here: https://github.com/ThePhysHub/ThePhysicsHub

The link to our Discord server is on our website (I don't know if posting Discord invites are allowed.). 

You can contact me here: brtymn@protonmail.com
I made a StumbleUpon-like website to discover awesome things (randomly)

Tags: webgl, stumbleupon
Published: 2020-10-17 20:27:14

Hello Dvs,

I used to like StumbleUpon early on and have so many great memories. I was really addicted. I miss this discovery engine that pushed the web content recommendation to its users. So I was looking for a substitute or something to replace it after shut down. Finally, I created a simple StumbleUpon-like website, a site that takes you randomly to amazing code-driven art, digital artworks
and other interesting stuff randomly: https://sharkle.com

Please let me know about this experiment, I welcome your feedback. Thank you.
Getting started with Mpesa Developer Portal
Tags: mpesa, api, getstarted
Published: 2020-10-17 20:26:22



## How to get started with Mpesa Developer Portal(as a dev)

> Steps to Signup as a developer

1. Goto to https://openapiportal.m-pesa.com/sign-up

2. Add First and Last name
	![image.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602962883746/9akWxO979.png)

3. Add Login Credentials including email, username, password, accept the terms and conditions.
	![image.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602962932149/IcMZjoaoT.png)

4. Check your email for a new mail, if you can't see it check in the spam folder

	![Screenshot at 2020-10-17 22-31-24.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1602963396073/D0HIE_dfL.png)

5. Login using your username and password, 

6. Using authenticator service like  [Google authenticator](https://play.google.com/store/apps/details?id=com.google.android.apps.authenticator2&hl=en) or [Microsoft  Authenticator ](https://play.google.com/store/apps/details?id=com.azure.authenticator&hl=en&gl=US), add the secret to the service and you will be provided with a 6 digit number, use that to finalize the login process.

7.	Upon successful login you will be redirected to a `Getting Started` page in the portal. 


## What can you do in the portal?

> The M-Pesa Developer Portal allows developers the following functions:

- Application Management - View, edit and create new integration services through applications by selecting products, defining their scope, and setting limits.
- Rapid Integration - Develop interfaces quickly by following detailed API documentation, examples, and library codes.
- Sandbox Testing - Secure and isolated testing environment to test interfaces and confirm responses through pre-determined scenarios.
- Developer and Organisation Linking – Connect with organizations and build new applications to integrate with Mobile Money.
- Push for Review Workflow – Initiate a seamless workflow to hand over integration configuration to linked organizations for testing and go-live
- Integrated Support Forum - Get help from experts in the field on various topics
- Dedicated Business Processes - Understand the flow of interfaces/interactions to build better products and inspire future integration services
I just completed my first Hacktoberfest!
Tags: hacktoberfest
Published: 2020-10-17 20:19:33

## Here is what I learned 

### It's okay to feel intimidated 

At first, I was very intimidated. The last thing I wanted to happen was to make a mistake on someone else's work. Like many of us, I occasionally give into imposter syndrome and feel like my work isn't valuable. Thankfully, DEV has been an incredibly resourceful community in helping first-timers find projects they can feel comfortable with. Some projects are as simple as adding your name to a contributors list. Whether you're a seasoned vet or a complete novice, there's plenty of support here. I encourage everyone to participate!

### There are plenty of projects to choose from 

I wasn't sure what sort of project I wanted to work on, but I did know that my time commitment in my personal life meant that my attention couldn't become bogged down in complex projects. I needed something short, yet rewarding. I noticed that a lot of projects had newbies writing algorithms such as selection sort, bubble sort, and many others. What luck! I need to occasionally review these for potential interviews and because, frankly, I'm terrible at them.  I was able to finish in about two days without many issues. 

### Don't sell yourself short!

This goes back to my first point about feeling intimidated. This is completely normal, but don't let it get in the way of trying something new. Remember, every great software engineer started fresh at some point. Get out there and fail until you succeed.
React Music (React Synth)
Tags: hacktoberfest, opensource, synth, react
Published: 2020-10-17 20:13:19

---
title: React Music (React Synth)
published: true
tags: hacktoberfest, opensource, synth, react
---

## React Music (Synth)

A synth project that the amazing [spianodev](https://github.com/spianoDev) and [jmdahle](https://github.com/jmdahle) and I built in react:

[https://github.com/spianoDev/react-music](https://github.com/spianoDev/react-music)