teleren/devto huggingface dataset:
Redux Basic Configuration and folder & files Mid.
Tags: javascript, react, redux
Published: 2023-03-10 05:03:47


Hi fellas , in this text I'll explain the basic redux files and folders admin this files are completely able to be save in to another folder,  if you have a big app or if you're building a big one also this is a nob to mid level text so you'll need to learn the basics cause if not maybe you gonna mix the knowledge and it will be hard and frustrating but let's move on 

first of all the extensions we'll gonna use on this:

npx create-react-app
npm i react-router-dom@6  install the router v6 dependency
npm i redux
npm i react-redux
npm i redux-devtools-extension
npm i redux-thunk

once he have a the npx complete and the un-useful files were deleted we need to create a new folder
inside the src folder called store and the file called store.js

repeating the same process we'll need to build another folder and file called actions, reducers, store & types

this is the structure, we want to build

```
src
├───actions
|      └ actions.js
├───reducers
|      └ reducer.js      
├───store
|      └ store.js
└───types
|     └ types.js
└───App.js
└───index.js

```
next we gonna type code and start to save the types as you've the redux use a switch to manage the actions in order to get, update, create or delete the properties on the stored object without mutate it out so instead we have all the logic on the same function let's split out

```

export const types = {

  authLogin: '[auth] auth login',

}

```

once we've built it out the next step is open the store.js and just to get in deeper this store will be the truth of all the info we gonna manage on the app 

concepts: like the name explain is the storage of the info that we want to manage  let's gonna think as a bag of objects were gonna be on it and after we gonna request and dispatch 

```

import { createStore, compose, applyMiddleware } from "redux";
import thunk from "redux-thunk";

import { rootReducer  } from "../reducers/rootReducers";

const composeEnhancers = (typeof window !== 'undefined' && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__) || compose;

export const store = createStore(
    rootReducer,
    composeEnhancers(
        applyMiddleware(thunk)
    )
)

```
Obtaining openGauss Resources
Tags: opengauss
Published: 2023-03-10 07:23:38

openGauss provides online resources that contain a lot of useful information, such as common syntaxes, descriptions, and examples. If you encounter any problem when using the database, you are advised to search for solutions on our website. In addition, you can communicate with openGauss users about your problems through the open source community or emails.

**Our Website**

Our openGauss website provides information about openGauss download, documents, open source community, certification, knowledge graph, security, and activities.

**·** Download: You can download the openGauss software package, connection tools, and support tools. The panorama of openGauss support tools is provided.
**·** Docs: describe the openGauss database, including the legal statement, release notes, product description, technical white paper, compilation guide, quick start, installation guide, administrator guide, developer guide, and tool reference. These documents also describe the architecture, functions, features, and usage of openGauss. A large number of examples are provided in the documents for your reference.
**·** Community: shows how to contribute to the open source community, as well as the community organization structure, and online communication methods.
**·** Connect: helps users tune in news, activities, videos, summits, and blogs related to openGauss.
**·** Certification: introduces the openGauss certification system and serves an entry for querying training information and certificates.
**·** Security: introduces the vulnerability management process of openGauss and releases security notices and CVEs.
**·** Code: Gitee and Github community entries.
**·** Knowledge: provides a knowledge graph of openGauss cluster management, database tools, database kernel, and database driver.

**openGauss Community**
openGauss has opened the database source code and an openGauss community has been established. openGauss encourages users to contribute to and cooperate with the community, hoping to jointly build an enterprise-level open-source database community that can integrate diversified technical architectures.

The openGauss community is organized based on different Special Interest Groups (SIGs) to better manage and improve the work process. SIGs are open to everyone to make contributions. Each SIG has one or more code repositories on the Gitee platform. You can commit issues, participate in issue discussions, pull requests, and review code in the code repository of an SIG. Table 1 lists common SIGs. You can find the SIGs that you are interested in from the SIG list. For details about how to contribute to the community, see Contribution.

Table 1 Common SIGs in the openGauss community

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pnutapoy1172lzd5hqtb.png)
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2iwomhe9qftmfplxl37g.png)
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lfwr4vhv34oyuxplunmd.png)
Provider pattern.
Tags: react, webdev, beginners, programming
Published: 2023-03-10 03:51:10


The provider pattern is one of the most basic patterns that allows understanding the context API on react and use context hook, sometimes is very hard to implement cause is weird if you are a beginner, the basic trouble here is that the props heritage is too hard to maintenance if you are making a UI that have to use the info stored on it, also if some data is needed on all the app we can make it using this pattern that is the main purpose.

![code-example-props](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2f9k81551wbjx0udrxwn.png)

As you can see in this image the props have passed through the children of this component and if this is spread along the app using a component stack will be hard to understand the code.

![props-context-diagram](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ldngnwupxy1kb3rks2le.jpg)

In this diagram, you'll see the props are passed through the parent down to the children and the context that is on the app sharing the info all around the app.

The context is just there, you have to call it and the code is clear than using props a plus is that you can mutate the state.

As you can see on this image we are using the context, that is included on the react.js create react app or create vite 

We have to make create a context wich can be (bollean, objetcs, arrays, numbers, string) that will be propagated all around the app.

![basic-context-structure](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/y13gxut3ualps6n0wi7o.png)

We need to use the children, this allow us to wrap the information from the context all around the app, and make the context callable usign the useContext() hook.

![context-structure](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/se6uoefzv3w0nzc9rrf0.png)

Now, this is an example, in a common react.js component.

![useContext-usage](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xim2t2lncc6u9q5ew2g7.png)

How, we are making a request to the global context, using useContext hook.

This allow us to make it out and get the info stored on it
Overview of different AWS events
Published: 2023-03-10 06:58:26

Author: Rajat Goel

AWS hosts a number of events throughout the year that provide opportunities for businesses to learn about the latest updates to the platform, network with other AWS users, and explore new technologies and solutions.

Here are some of the key AWS events that you should know about:

- AWS re:Invent: AWS re:Invent is the largest AWS event of the year, with over 60,000 attendees from around the world. The event takes place in Las Vegas and features five days of keynotes, sessions, and workshops covering all aspects of AWS. Attendees can learn about the latest AWS services, network with other AWS users, and get hands-on experience with new technologies.

- AWS Summit: AWS Summit is a series of events held in various cities around the world. These events are designed for developers, IT professionals, and business leaders who want to learn more about AWS and its services. Attendees can attend sessions and workshops to learn about best practices, new services, and real-world use cases.

- AWS re:Inforce: AWS re:Inforce is a security-focused event that takes place annually in Boston. The event features keynote presentations, breakout sessions, and hands-on labs focused on security and compliance in the cloud. Attendees can learn about best practices for securing their cloud environments, as well as new AWS security services and features.

- AWS Global Summits: AWS Global Summits are a series of one-day events held in various cities around the world. These events are designed to provide attendees with an overview of AWS services and best practices. Attendees can attend sessions and workshops to learn about topics such as application development, infrastructure, security, and more.

- AWS Startup Day: AWS Startup Day is a one-day event designed for entrepreneurs and startup founders. The event provides an opportunity to learn about AWS services and best practices, as well as network with other startups and AWS experts. Attendees can attend sessions and workshops focused on building and scaling their businesses in the cloud.

- AWS Public Sector Summit: The AWS Public Sector Summit is a two-day event designed for government, education, and non-profit organizations. The event provides an opportunity to learn about AWS services and best practices for the public sector. Attendees can attend sessions and workshops focused on topics such as security, compliance, and innovation.

In addition to these events, AWS also hosts webinars, online training courses, and other virtual events throughout the year. These events provide opportunities to learn about AWS services and best practices, regardless of where you are located.

Overall, attending an AWS event can be a valuable experience for anyone who is interested in learning more about cloud computing and AWS services. Whether you are a developer, IT professional, business leader, or startup founder, there is an AWS event that is designed for you. So, be sure to check out the AWS events calendar and register for the events that interest you the most.
What is Generative AI ? and It's Impact on Businesses.
Tags: generativeai, ai, webdev, deeplearning
Published: 2023-03-10 06:54:25

Now a days this topic is hot in market. Every where we see its uses, so let's come to the point straight. 
It is a type of artificial intelligence that focuses on creating or generating new content, such as images, videos, music, or text, that has not been seen or heard before.

Generative AI models are trained on a large dataset of existing content and use various algorithms to analyze and learn the patterns, styles, and characteristics of the data. Once the model is trained, it can generate new content that is similar in style and structure to the original dataset.

Generative AI has many applications in various fields, such as art, music, fashion, gaming, and advertising. For example, a generative AI model can be used to create new clothing designs, generate unique music compositions, or create realistic video game characters. It can also be used to create conversational agents or chatbots that can generate natural language responses to user inputs.

The impact of generative AI on businesses can be significant. Some potential benefits include:

1. Content creation: Generative AI can help businesses to automate content creation, generating images, videos, or written content for marketing campaigns or other purposes.
2. Personalization: Generative AI can be used to create personalized content for customers, such as customized product recommendations or targeted advertising.
3. Design: Generative AI can assist in product design, creating and iterating on design options in real time.
4. Cost reduction: Generative AI can help businesses to reduce costs by automating tasks that would otherwise require human labor.
5. Innovation: Generative AI can help businesses to explore new creative ideas and generate innovative solutions to complex problems.

However, generative AI also presents some challenges, such as ethical concerns around the potential misuse of generated content or the potential biases inherent in the data used to train the models. Nonetheless, the potential benefits of generative AI make it an area of growing interest and investment for businesses.

> “Before we work on artificial intelligence why don’t we do something about natural stupidity?” —Steve Polyak
Hooks useState & useEffect
Tags: beginners, programming, react, frontend
Published: 2023-03-10 06:44:09

Now is the turn of the react.js hooks means the main functionality of the react.js, sometimes at the beginning of the learning route is a little bit hard to understand cause there is a level of abstraction on those, basically you can learn it, but understanding these are a pre-code container which allows us to make some changes, keep alert for a change on the app, save states on the page, etc.

The question here is: 
what does it make?
how can I use it?

useState

This hook allows us to make some changes to the state of the page, I mean you gonna save something on the state (object, number boolean, string, array, etc.)

the structure is easy to understand :


![useState-hook](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jnvgf337ogl2zw7jhh78.png)

useEffect 

This hook allows us to handle state and lifecycle methods for a component 

this hooks is a listener of a change that renders the virtual DOM when a change is made, 

![useEffect-hook](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/y5kjxur36iyu0e3uwv69.png)
Dental Milling Machine
Tags: dentallabmillingmachine, dentalmillingmachine, cadcammillingmachine
Published: 2023-03-10 06:16:34

The Benefits of Investing in a Denture Milling Machine for Your Dental Practice
Denture milling machines are becoming increasingly popular in the dental industry due to their numerous benefits for dental practices. Investing in a denture milling machine can offer significant advantages that can improve the quality of care provided to patients, increase efficiency, and ultimately lead to greater profits. Here are some of the main benefits of investing in a denture milling machine for your dental practice:
Faster Turnaround Times: One of the main advantages of using a denture milling machine is the speed at which dentures can be produced. Traditional denture manufacturing processes can take several days or even weeks, whereas a milling machine can create a denture in a matter of hours. This means that your practice can provide faster turnaround times for patients, which can improve their satisfaction with your services.
Improved Accuracy: Denture milling machines use advanced technology to create precise and accurate dentures. The milling process ensures that each denture is made to exact specifications, resulting in a better fit for patients. This can reduce the need for adjustments or remakes, saving your practice time and money.
Consistency: With traditional denture manufacturing processes, there can be a lot of variability in the quality of dentures produced. However, denture milling machines are designed to produce consistent results every time, ensuring that your patients receive dentures of the same high quality each time they visit your practice.
Cost Savings: While the initial investment in a denture milling machine may seem high, it can result in cost savings in the long run. By reducing the need for adjustments and remakes, you can save money on materials and labor costs. Additionally, faster production times can allow you to take on more patients and increase your revenue.
Improved Patient Satisfaction: Ultimately, investing in a denture milling machine can lead to greater patient satisfaction. Patients will appreciate the faster turnaround times, better fit, and consistent quality of the dentures produced. This can lead to increased loyalty and referrals, which can further benefit your practice.

In conclusion, a denture milling machine can offer numerous benefits for dental practices, including faster turnaround times, improved accuracy and consistency, cost savings, and greater patient satisfaction. If you are considering investing in a denture milling machine for your practice, it is important to carefully evaluate your options and choose a machine that meets your specific needs and budget.
현금영수증 조회방법 – 10초만에 확인할 수 있습니다
Published: 2023-03-10 06:15:06

현금영수증 조회방법 – 10초만에 확인할 수 있습니다
연말정산이나 종합소득세를 위해 현금영수증을 조회해야할 때가 있습니다. 현금영수증은 온라인으로 간편하게 조회가 가능합니다.

현금영수증을 발급받은 내역을 조회하기 위해서는 국세청의 홈택스 혹은 모바일 손택스 등으로 조회할 수 있습니다.

직장인이라면 소득공제를 받을 수 있으며 사업자라면 지출증빙용 자료로 활용이 되기 때문에 꼭 발급받는 것이 좋습니다.

현금영수증 조회를 통해 현금영수증 내역을 통합하여 확인할 수 있습니다. 자세한 내용은 뉴스채널을 참고하세요.

https://microbia.co.kr/cash-receipt-inquiry/
AWS CDK stack for building Amazon EventBridge Pipes (SQS to CloudWatch Logs)
Tags: aws, awscdk, eventdriven
Published: 2023-03-10 06:12:12

I have released an AWS CDK(v2) stack that builds the following Amazon EventBridge Pipes.

This stack provides a quick experience in building Amazon EventBridge Pipes.

{% embed https://github.com/ma2shita/cdk-eventbridge-pipes-simplelogger %}

If you are on AWS Cloud9, you can `cdk bootstrap` immediately because the environment is ready up to the cdk command. 

## Contains "enrichment" Lambda functions

"Enrichment" can invoke Lambda function and Step Function, reducing the amount of code compared to a stand-alone Lambda implementation.

This CDKv2 stack contains Lambda functions that can be called from "enhancements". It is ["do nothing" code](https://github.com/ma2shita/cdk-eventbridge-pipes-simplelogger/blob/main/lambda/lambda_function.py), though, so please see it as a framework.
How to customize it is described below.

## Customization Points

### On the "Enrichment" function

The "enrichment" function allows editing of the payload. For example, you can lookup items from DynamoDB by the input then  append the results to the payload.

For specifications of the Lambda function to be specified for enhancement, see here. 
[AWS Lambda function specifications in "Enrichment" in Amazon EventBridge Pipes](https://dev.to/ma2shita/aws-lambda-function-specifications-in-enrichment-in-amazon-eventbridge-pipes-5anb)


### On the "Target" of EventBridge Pipes

Once you have changed the "target", remember to grant write permission to the destination service to the Pipes Execution role.
In particular, `events:InvokeApiDestination` is required if you specify an "API destination" that can send to an external API.

## Conclusion and "CDKv2 for IoT 1-Click"

I'd love to hear your feedback!  
And, an AWS CDK(v2) stack for creating AWS IoT 1-Click projects is also available. Button data can be sent to Amazon EventBridge Pipes.

{% embed https://github.com/ma2shita/cdk-iot1click-project-to-sqs %}

So, It would be nice if IoT 1-Click would support sending directly to SQS. :-)

EoT
Running the Latest Safari WebKit on Windows
Tags: webdev, tutorial, productivity, safari
Published: 2023-03-10 06:06:09

## Safari runs on Windows!?!

I can't believe it took me this long to figure this out, but it's totally possible to run the latest WebKit/Safari on Windows locally and debug issues that would otherwise require emulation, a remote machines or a Mac!

Not only can it be done but it's extremely easy to do, and in this article I will go over the 2 simplest ways to get up and running.

## Method #1: Playwright CLI

This first method is by far the easiest as it only requires having [Node.js](https://nodejs.org/en/) installed which comes with npm/npx. Once you have Node.js installed you will need to run the [Playwright](https://playwright.dev/) command to download the browsers.

Open up the Command Prompt and type `npx playwright install`, then once this is done you can open up a url in WebKit by running the follow command `npx playwright wk https://dustinbrett.com/`, as described in the docs for [Command line tools -> Open Pages](https://playwright.dev/docs/cli#open-pages).

![MiniBrowser.exe](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/i7ln33n3u897ef4lhs4t.png)

## Method #2: Download Build Artifacts

As described in the [Webkit Wiki](https://trac.webkit.org/wiki/BuildingCairoOnWindows#DownloadbuildartifactsfromBuildbot), the files required are built often and can be easily downloaded and combined.

The first file that is needed comes from the [Webkit CI Builders](https://build.webkit.org/#/builders), specifically `WinCairo-64-bit-Release-Build`.

![Webkit CI Builders](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ko9sus4nyvdvsd58bytg.png)

Open the latest green build and download the zip file mentioned after `S3 URL` on the `transfer-to-s3` step.

![Download From S3](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s0n9h7fn7p4t8m7hd23s.png)

Now you will need to download one more zip file from the [WebKitForWindows Releases](https://github.com/WebKitForWindows/WebKitRequirements/releases) by downloading `WebKitRequirementsWin64.zip` from the `Assets` section of the most recent release.

Then extract both files to the same folder so that the `bin64` folders become combined. All other folders can be deleted as they are not needed. Go into the combined `bin64` folder and launch `MiniBrowser.exe` and you are up and running.

This version has more features compared to the Playwright one and allows turning on and off Experimental & Internal Debug Features.

![Experimental & Internal Debug Features](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/biruu85g6h4zvvsbhv04.png)

Both versions have the familiar Web Inspector which is extremely helpful to have locally.

![Web Inspector](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vfipyma5pr40wghhrp3f.png)

## Companion Video

I thought this was such a useful trick that I also made a video showing how to do it, feel free to check it out!

{% youtube W3IH7zDR_HQ %}