teleren/devto huggingface dataset:
EOD Stock Market API for developers
Tags: freestockmarketapi, stock, stockmarketapi, webdev
Published: 2023-05-02 10:31:53

As a developer, you know how important it is to have access to reliable and accurate data when it comes to the **stock market**. With the rise of digital technologies, accessing this data has become easier than ever before, t**hanks to APIs or Application Programming Interfaces**. APIs allow developers to access data from various sources, including financial markets, and use that data to build applications and services.

![EOD Stock Market API](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/r9vgtne2uve1vx7wqtvk.PNG)
One such API that stands out in the market is the **[EOD Stock API](https://eod-stock-api.site)**. 

**[With its Basic Plan, developers can access a wealth of financial market data](https://eod-stock-api.site/plan-descriptions/basic)**, including exchanges, stock tickers, end-of-day (EOD) data, and financial news. The plan offers 5000 requests per month, with 10,000 records per request, making it an ideal solution for developers who need to intergrate their website or applications with our API.

**[Moreover, with API documentation access, developers can easily integrate the EOD Stock API into their applications](https://eod-stock-api.site/redoc)**, without worrying about data accuracy and reliability. 
The Basic Plan also comes with limited email support, ensuring that developers have the necessary assistance when they need it.

In addition, **the EOD Stock API offers a 1-month free trial**, giving developers the opportunity to test the API and see if it meets their needs. 

This not only allows developers to evaluate the product, but also helps to build trust and confidence in the EOD Stock API.

**[If you are interested please create your free 1 month trial account today and get access to your API Key](https://eod-stock-api.site/plan-descriptions/basic)**

In conclusion, the EOD Stock API is an excellent option for developers who need reliable and accurate financial market data. With its Basic Plan, developers can access a range of features, including exchanges, stock tickers, EOD data, and financial news, all backed by a 1-month free trial and limited email support. By choosing the EOD Stock API, developers can focus on building their applications and services, while leaving the data processing to the experts.
Announcing Medusa’s Community Publication
Tags: opensource, news, showdev, writing
Published: 2023-05-02 10:18:47


At Medusa, we’re introducing our new community publication, [Medusa Community](https://medusa-community.hashnode.dev/welcome-to-medusas-community-publication), hosted on Hashnode. This publication gives writers interested in writing about Medusa a platform where they can be recognized and paid for their work.


Keep reading below to learn more about this publication and how you can join!


## Why create a community publication?


Last year, we created a Writers Program at Medusa, where we were able to work with over 200 writers in producing content related to Medusa. This has allowed us to create diverse content of different types and levels based on the different skills the community writers provided.


As the Writers Program continued to grow and gain interest, we realized how important it is to highlight the community’s work and make it easier for more people to contribute and join. The community publication aims to solve a lot of the limitations we had with the Writers Program, while also providing creative and useful content for the community, by the community.


## How does it work?


We share all the details about the new publication in our new [Write for Us page](/74a2bf43b4ce43eeba200382f599321a). To sum it up:

- You can join as a writer using [this form](https://ky5eo2x1u81.typeform.com/to/J6lDIwtJ).
- You’ll then receive an email with the details to join the Hashnode publication and any other necessary resources.
- That’s it! You can then start writing and submitting content to the community publication.

### Important notes

- It’s important to sign up again as a writer using the form mentioned above, even if you were previously part of the Writers Program.
- Your article must match our [writing guidelines](/8f3be54b95654fe8bfbb45503e7eed8a).
- Articles are not instantly published on the publication, as we might specify a schedule on how and when we decide to post the article.
- You’ll receive payment if your article is published or scheduled.
- Although you can generally write about anything related to Medusa, we also have guidelines on what topics we are against and some things to keep in mind when writing. You can learn more [here](/8f3be54b95654fe8bfbb45503e7eed8a).

## Benefits of joining the Community Publication

- Your content will be recognized by the Medusa community. We’ll also often share articles we find insightful or creative across our channels.
- You’ll get paid for your work. We also offer bonus payments if your article gets featured on Hashnode or other publications.

## Start writing for Medusa


Interested in the Community Publication? You can join the publication through [this form](https://ky5eo2x1u81.typeform.com/to/J6lDIwtJ).


Check out the Medusa Community Publication and follow it on Hashnode to stay updated with all community content.
Building a course landing page with NextJS and Tailwind
Tags: webdev, javascript, beginners, programming
Published: 2023-05-02 10:00:05

# TL;DR
I have been working for [Novu](https://github.com/novuhq/novu) over the last year and have gained crazy growth
Can you believe that we got `20,000` stars in just one year? 🤩

It got me thinking about how to help other people grow their GitHub libraries, so I created the [GitHub 20k course](https://github20k.com).

But that's boring. The important part is that I open-sourced it
https://github.com/github-20k/super-star

And I want to tell you how I did it :)

![The office I did it](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ynq6w0kygdr6p2h42kuy.gif)

## Architecture 
First, I had to decide about the tech. I wanted to make it as easy as possible for any developer to use it for their personal use.

So I decided to go for NextJS because I can use NextJS backend - instead of a separate project or a mono repo.

And also with Tailwind so that CSS won't be necessary.

There is no database, everything is stored in JSONs, and I created multiple providers so people could make what they need for themselves or contribute to the project.

### The flow
I wanted to make the easiest possible way to create a sales page.

So all we have is three stages.

1. You go to the sales page
2. You go to a checkout
3. you trigger multiple services

![UML](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/k4nqcs79vrfngewou49g.png)

When I completed it, I said, why not have a blog?
So I added a blog based on headless WordPress, but I wrapped everything up so you can use any other service such as Sanity.

When you go to the blog, you can see it was not a designer that made it 🤣

I actually used ChatGPT to draw some grids because I am so bad with them.

![Blog](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/e6q6ppe9k4fgmo2iv93o.png)

## Design
One of the hardest things to find usually is, **designers**.
There are many, but most of their work usually looks the same.
I had to scan Dribbble many times to find something I liked.

![Design](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/oacbt9kfj8ytxefu5iry.png)


Some might say it could be more graphical, and people can't focus on the page's content, but I like it.

![I like it](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7n37kf439ft7augd9pqd.gif)



If you want to use the landing page and are not sure how, just read the docs, made with [Docusaurus](https://docs.github20k.com/)

## Can you help me out?
I have been working super hard to make it available for everyone needing a landing page. I love this community so much ❤️
Be a friend, and help me with a star
https://github.com/github-20k/super-star

Check also [How to get GitHub stars](https://howtogetgithubstars.com)
How to Make Your Website More Accessible with prefers-reduced-motion
Tags: a11y, programming, webdev, css
Published: 2023-05-02 09:54:52

### Introduction:
If you're building websites or web applications, it's important to make sure that everyone can use them, regardless of any accessibility challenges they may face. One accessibility issue that can affect some users is motion sickness or discomfort caused by animations and other motion effects on the page. That's where `prefers-reduced-motion` comes in.

### Understanding `prefers-reduced-motion`
`prefers-reduced-motion` is a media query that can be used in CSS to detect whether the user has requested reduced motion on their device or browser. The possible values for `prefers-reduced-motion` are no-preference and reduce. If the user has requested reduced motion, any animations or other motion effects on the page should be disabled or scaled back.

Here's an example of how to use `prefers-reduced-motion` in CSS:

```css
@media (prefers-reduced-motion) {
  /* Disable or scale back animations and motion effects */
}
```

### Examples of `prefers-reduced-motion` in action
Here are some examples of how you can use `prefers-reduced-motion` to create a more accessible user experience:

- If you have a slideshow or carousel on your page, you can disable automatic animation when `prefers-reduced-motion` is set to reduce, so that the user can manually advance the slides without being bombarded with automatic motion effects.

- If you have a navigation menu that slides in and out of view, you can disable the sliding animation when `prefers-reduced-motion` is set to reduce, so that the menu appears instantly without any motion effects.

- If you have a hover effect on your links or buttons, you can disable the effect or change it to a more subtle effect when `prefers-reduced-motion` is set to reduce, so that the user doesn't experience any sudden or distracting motion.


[prefers-reduced-motion demo](https://codepen.io/PunitSoniME/pen/BaqwYQj)

You can see the smooth scroll animation if you operating system's Animation is enabled.
If you disable the operating system's Animation, smooth scrolling will no longer visible

[Enable Disable Animation in Windows](https://support.microsoft.com/en-us/office/turn-off-office-animations-9ee5c4d2-d144-4fd2-b670-22cef9fa025a)

### Conclusion:
By using `prefers-reduced-motion` in your CSS, you can make your website or web application more inclusive and accessible to users who may experience discomfort or motion sickness from animations and other motion effects. It's a simple but powerful tool that can help you create a more welcoming and inclusive online experience.


### Follow me on
[Twitter](https://twitter.com/PunitSoniME)
[Github](https://github.com/PunitSoniME)
[LinkedIn](https://www.linkedin.com/in/PunitSoniME)
8 Tips to Master JavaScript Programming: From Basics to Frameworks
Tags: javascript, tutorial, beginners
Published: 2023-05-02 09:35:18

1. Master the basics: Before you dive into complex programming concepts, make sure you have a solid understanding of the basics. This includes variables, data types, control structures, functions, and objects.

2. Practice, practice, practice: The best way to improve your skills is to write code. Create small projects, work on code challenges, or contribute to open source projects.

3. Keep learning: JavaScript is a constantly evolving language, so it's important to stay up-to-date with the latest developments. Read blogs, watch tutorials, and attend conferences to keep your skills sharp.

4. Understand asynchronous programming: JavaScript is designed to handle asynchronous tasks, which can be a challenge for new programmers. Learn how to use promises, async/await, and other tools to manage asynchronous code.

5. Use debugging tools: Debugging is an essential part of programming, and JavaScript offers a range of tools to help you identify and fix errors. Learn how to use the browser console, debugger, and other debugging tools to streamline your workflow.

6. Write reusable code: Writing reusable code is a great way to save time and reduce errors. Learn how to write functions, classes, and modules that can be reused across your projects.

7. Embrace best practices: Follow best practices when writing JavaScript code. This includes using consistent naming conventions, commenting your code, and following style guides.

8. Learn a framework: JavaScript frameworks like React, Angular, and Vue can help you build complex applications more quickly and efficiently. Learn at least one of these frameworks to expand your skillset.

Remember, becoming a better JavaScript programmer takes time and dedication. Keep practicing and learning, and you'll soon become a master of this powerful language!
Please share your ideas and techniques for others in the comment section. 🙏🏽
Mocking vs Stubbing
Tags: react, testing, cleancode
Published: 2023-05-02 09:32:28

𝐌𝐨𝐜𝐤𝐢𝐧𝐠 !== 𝐒𝐭𝐮𝐛𝐛𝐢𝐧𝐠

When it comes to testing your react applications, we typically do not test the actual API calls, we instead use test doubles 

Test doubles is the general term for defining objects that are not real. Mocks and stubs are a part of a class of test doubles. They are a kind of pretend  object used in place of a real object for testing purposes. This term includes dummy, fake, stub and mock.

**Mocking and stubbing are often used interchangeably but they are not the same.**

They both involve using fake objects to manage and isolate side effects. Mocking and stubbing are two software techniques used to create controlled and predictable environments for testing code, but they differ in their approach and purpose.

## **Mocking**

This is the technique of creating a fake object that mimics the behaviour of a real object, typically for the purpose of testing interactions between objects. Mock objects verify that the tested code correctly 𝐜𝐚𝐥𝐥𝐬 𝐦𝐞𝐭𝐡𝐨𝐝𝐬 𝐨𝐧 𝐭𝐡𝐞 𝐦𝐨𝐜𝐤𝐞𝐝 𝐨𝐛𝐣𝐞𝐜𝐭 and that the expected results are returned.


## Stubbing

On the other hand, is the technique of creating a fake object or function that returns 𝐩𝐫𝐞𝐝𝐞𝐟𝐢𝐧𝐞𝐝 𝐯𝐚𝐥𝐮𝐞𝐬, typically for the purpose of testing specific code paths. Stub objects are used to simulate the behaviour of a real object or function, but without actually performing the full functionality. Stubbing is often used to test error handling, and edge cases, or to isolate a specific piece of code for testing.

**Some of their Key differences include:**

## Style

**Mocks** tests for the behaviour of the unit
**Stubs** tests for the state of the unit

## Principle

According to the principle of testing only one thing per test, there may be several stubs in one test, but generally, there is only one mock.

## Lifecycle

**Test lifecycle with stubs:**

1. Setup - Prepare the object that is being tested and its stubs collaborators.
2. Exercise - Test the functionality.
3. Verify state - Use asserts to check the object's state.
4. Teardown - Clean up resources.

**Test lifecycle with mocks:**

1. Setup data - Prepare the object that is being tested.
2. Setup expectations - Prepare expectations in mock that are being used by the primary object.
3. Exercise - Test the functionality.
4. Verify expectations - Verify that correct methods have been invoked in mock.
5. Verify state - Use asserts to check the object's state.
6. Teardown - Clean up resources.

## Practical use-case

Mocking makes sense to assert navigation within React app. In the integration test we could create a mock of the navigate function and spy on whether it was called at a certain time while interacting with the page.

Stubbinng is more popular, especially stubbing the state of out-of-process dependencies like:
- An API request
- Operation on browser cookies
- An interaction with an external SDK
- Operations on the URL in the browser
- An interaction with a Web Storage (local/session storage)

![A practical implementation of mock](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/abz2okmc0y65wzgd36lb.png)
Integration Digest: April 2023
Tags: api, kafka, kong, cloud
Published: 2023-05-02 08:51:34

📢 The April 2023 Integration Digest is now live! 🚀

Dive into the world of APIs, integration architecture, and vendor updates with this month's comprehensive roundup. You'll find insights on API maturity, monetization, governance, documentation best practices, and so much more! 💡

🔗 Articles include:
- 5 Pillars of Modern API Maturity
- 8 Tips For Monetizing Your API
- AsyncAPI Documentation Report - Q1 2023
- Best Practices: API Rate Limiting vs Throttling
- Introducing the IATA API Style Guide for the Aviation Industry

🛠️ Vendor updates from:
- Apache Kafka & Confluent
- Gravitee.io
- Kong
- IBM
- MuleSoft
- SAP
- SnapLogic

🎉 New releases:
- Debezium 2.2.0
- Anypoint Flex Gateway 1.4.0
- RabbitMQ 3.11.15
- NATS Server 2.9.16
- Camunda Desktop Modeler 5.10

Stay ahead of the curve, and check out our latest Integration Digest for April 2023! 🌐

Link: https://wearecommunity.io/communities/integration/articles/3148
Python program to taking screenshots
Published: 2023-05-02 08:49:18

---
title: Python program to taking screenshots
published: true
description: 
tags: 
# cover_image: https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jq1ut5yl8xilx9xt70s1.png
# Use a ratio of 100:42 for best results.
# published_at: 2023-03-22 18:13 +0000
---

In this article, We will create a program in Python that will take screenshots on our computer.So don’t waste your time, open your computer quickly.

In order to take screenshots we need to install a module that can control the mouse and keyboard of our computer, one such module is PyAutoGUI.

To install PyAutoGUI type the below command in the terminal.

```bash
pip install pyautogui
```

Now we need to install the pillow package.To install Pillow type the below command in the terminal.

```bash
pip install Pillow
```

It’s will take few seconds to install. After installed, we now need to write a program that will take screenshot after 5 seconds.

Below is the implementation.

```python
#Python Program to taking a screenshot
 
#To import pyautogui module
import pyautogui 
 
#To import time module
import time 
 
#To take screenshot after 5 seconds
time.sleep(5) 
 
#To take screenshot 
screenshot = pyautogui.screenshot() 
 
#To save the screenshot
#This image will be saved inside this directory
screenshot.save('image.png')  
 
#Will print a message in terminal, after taken the screenshot
print('screenshot taken.') 
```
ChatGPT-4 vs ChatGPT-3 vs Golang
Tags: go, chatgpt, ai
Published: 2023-05-02 08:43:39

ChatGPT 3 [didn't do so well](https://youtu.be/OldZ3hAgsqQ) when quizzed about Go.

But now we have ChatGPT 4.  How does it do?  Watch to find out!

{% youtube https://youtu.be/qxaLdfuj6NU %}
Howtouselinux Newsletter (April 2023)
Tags: linux, beginners, tutorial, productivity
Published: 2023-05-02 07:03:47

We hope this newsletter finds you well. This past month has been a busy one for HowToUseLinux, as we've been working hard to bring you the latest and greatest information.


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

Firstly, we have two ways to [fix the "cp Permission denied"](https://www.howtouselinux.com/post/fix-cp-permission-denied) error. This is a common error that users face while trying to copy files in Linux, and our article provides some easy solutions to overcome it.

| **Method** | **Description** |
| --- | --- |
| Use sudo | Prepend the `cp` command with `sudo` to execute it with root privileges, which may provide the necessary permissions to complete the copy. For example: `sudo cp source_file destination_directory` |
| Change ownership | Use the `chown` command to change the ownership of the source file or destination directory to the user executing the `cp` command. For example: `sudo chown username:username source_file` or `sudo chown username:username destination_directory`. |
| Change permissions | Use the `chmod` command to change the permissions of the source file or destination directory to allow the user executing the `cp` command to read, write, and/or execute the file or directory. For example: `sudo chmod 777 source_file` or `sudo chmod 777 destination_directory`. |

Next, we have three ways to [check RPM package dependencies in Linux](https://www.howtouselinux.com/post/check-rpm-package-dependency-in-linux). This is a crucial step when installing new packages and our article provides some simple commands to ensure you have all the dependencies in place.

| **Method** | **Command** |
| --- | --- |
| Using rpm -q option | `rpm -q --requires package.rpm` |
| Using yum deplist command | `yum deplist package.rpm` |
| Using repoquery tool | `repoquery --requires package.rpm` |
| Using dnf repoquery command | `dnf repoquery --requires package.rpm` |

In addition, we have six ways to troubleshoot the "[ssh: connect to host port 22: Connection timed out](https://www.howtouselinux.com/post/ssh-connect-to-host-port-22-connection-timed-out)" error. This can be a frustrating error, but our article provides you with several solutions to get your SSH connection up and running smoothly.


Furthermore, we have four ways to [list files within an RPM package in Linux](https://www.howtouselinux.com/post/list-files-within-a-rpm-package-in-linux). This can be a handy tool when you need to check the contents of an RPM package before installing it.

Lastly, we have an article on [how to use the Linux systemctl command](https://www.howtouselinux.com/post/how-to-use-linux-systemctl-command). This command is used to manage services in Linux, and our article provides some simple examples to get you started.

We hope you find these articles helpful and informative. Stay tuned for more exciting content from us in the future.
WordPress Safe Email Testing with Postbox Plugin (Email Log)
Tags: wordpress, webdev, php
Published: 2023-05-02 08:39:23

WordPress email testing with PostBox plugin. It saves WordPress email logs. You can view email details like subject, To, cc, Bcc, etc.


![WordPress Email Log](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/l400cljikhgj4j99m7tn.png)

## How to use the WordPress email log plugin?

Step 1: Go to **wp-admin > plugins >** then search PostBox [Email Log](https://wpdebuglog.com/wordpress-email-logs/)

![WordPress Email Logging](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x2mz6udzruf6gt0xr7jq.png)

Step 2: Then install and activate the plugin.

Now it will automatically start to capture the email details that were sent from WordPress.

It will work like, WooCommerce Email Log or any other WordPress plugin.

## How WordPress Email Logging is Working?
The WordPress email logging plugin is hooked to wp_mail. Then store information in the database. No need for any external fake SMTP server like Mailtrap.

## Is it Work with SMTP WordPress Plugin?
Yes, It will work with WordPress SMTP plugins like SMTP7. Most of web servers disable the PHP email function. We can enable the email option by SMTP.
ACID PROPERTIES IN DATABASE
Tags: database
Published: 2023-05-02 08:24:55

Question : What is ACID Properties in SQL  Database ? 

1. A-> Atomicity: all the transaction in database should be atomic. it means that all the transaction step should be executed or whole transaction can be rolled back. 
C-> Consistency: this is spoken in terms of consistency. if there is any write written, then the read just after that should get the right data. data should not be stale data and it should be consistent. 
I-> Isolation: Multiple transactions should happen independently across the database without interfering with other transactions. 
D-> Durability: the changes occurs in the database are successful even if there is system failure or error occurs