teleren/devto huggingface dataset:
Fetch with AbortController
Tags: frontendchallenge, devchallenge, javascript, webdev
Published: 2024-03-22 12:12:16

_This is a submission for DEV Challenge v24.03.20, One Byte Explainer: Browser API or Feature._

## Explainer
```js
async function go(u,t,o,s=null){try{const r=await fetch(u,
{...o,signal:s});if(!r.ok)throw new Error(`HTTP
error:${r.status}`);return t==='json'?await r.json():
(t==='text'?await r.text():r);}catch(e){throw 
e.name==='AbortError'?new Error('Timeout'):e;}}
```

## Additional Context
**Explain `fetch()` with return type and `AbortController` in 256 bytes.**

The above is **252 bytes** — the explaination will be longer 😂

The method has 4 parameters:

- u (URL)
- t (return type: 'json', 'text' — or leave blank to get the `response`)
- o ([options](https://developer.mozilla.org/en-US/docs/Web/API/fetch))
- s (AbortController.signal)

---

## Examples

Basic `fetch`, return `response`

```js
const data = await go(
  'https://jsonplaceholder.typicode.com/posts/'
);
```

Basic `fetch`, return `response` as `json`:

```js
const data = await go(
  'https://jsonplaceholder.typicode.com/posts/',
  'json'
);
```

Use it with an `AbortController`, to cancel the `fetch()` under certain conditions (timeout being the most common):

```js
const controller = new AbortController();
const signal = controller.signal;
const data = await go(
  'https://jsonplaceholder.typicode.com/posts/',
  'json',
  {},
  signal
);
```

Then, to abort the `fetch()`, use `controller.abort()`. 

In this example, after 5 seconds:

```js
setTimeout(() => controller.abort(), 5000);
```

[Photo by Dapo Abideen](https://www.pexels.com/da-dk/foto/morgengry-himmel-solnedgang-romantisk-5677459/)
Glam Up My Markup - Cozy Camp
Tags: frontendchallenge, devchallenge, css, javascript
Published: 2024-03-22 12:05:36

_This is a submission for DEV Challenge v24.03.20, Glam Up My Markup: Camp Activities_

## What I Built
<!-- Tell us what you built and what you were looking to achieve. -->
This was a very fun challenge.
I explain the details of this journey after the demo.


## Demo
<!-- Show us your project! You can directly embed an editor into this post (see the FAQ section from the challenge page) or you can share an image of your project and share a public link to the code. -->
{% codepen https://codepen.io/rodrigoant/pen/rNbmNYe %}


## Journey
<!-- Tell us about your process, what you learned, anything you are particularly proud of, what you hope to do next, etc. -->

I started by choosing the colors. I wanted to deliver a cozy and warm vibe, so I used CSS Variables to help me remember them.
```css
:root {
  --color-camp-01: #738d5e; // muted green
  --color-camp-02: #293d31; // rich green
  --color-camp-03: #ffc78a; // warm golden
}
```


Looking at camp inspiration designs, I found strong typography, colorful contrasts and nature-inspired illustrations. Fonts are always hard to choose, so I made up my mind on `Truculenta` and kept moving forward.


![Truculenta from Google Fonts](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ffzdd4dbrr5g2vejw4n7.png)


Ok, time to build the thing.
Since we cannot edit the HTML, with flexbox I manage to achieve something like this.
Looks fine, but there is still some work to be done.

![Form v1](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ppfah6xzww0vpbk45lag.png)


This is more of a mobile-first approach, since on desktop we have more room to work with, I thought about changing the direction of the flex elements. And using the `:after` pseudo element so I could place something inside the `<h1>` tag. 
I used an SVG from game-icons library.

![Camp fire SVG from game-icons](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/c4lbfefu3kbhltvi1hsn.png)


Putting it all together, we have this:

![Form v2](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mk88ejm3r0slp1itq0v8.png)

Good, we are getting somewhere.
Although, there is something missing 🤔

Getting back at the camp designs inspiration, I found some rough edges designs, and things that give some organic look. So I decide to try some `border-image` css to see how it looks.

![Form v3 - Final](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rosobag4kq9c65kczk7j.png)


Now, about the feedback when the form is sent?
Since I started this thinking about cozyness, we need some smooth animations:

![Animated Gif of the form submission](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ga2amijron4yb2xngu1h.gif)


At the last minute I decide to increased spacing between elements for improved readability 😊

Thank you Dev.to team for creating this challange. 


<!-- We encourage you to consider adding a license for your code. -->

<!-- Don't forget to add a cover image to your post (if you want). -->


<!-- Thanks for participating! -->
How to Make Marksheet In Excel
Tags: excel, microsoft, powerpoint
Published: 2024-03-22 12:05:07

Creating a marksheet in Excel is relatively straightforward. You can follow these steps:
1.	Open Excel: Open Microsoft Excel on your computer.
2.	Set up Columns: You'll typically have columns for student names, roll numbers, and marks obtained in different subjects. You can customize this based on your specific requirements. For example, you might have columns like:
•	Student Name
•	Roll Number
•	Subject 1 Marks
•	Subject 2 Marks
•	...
•	Total Marks
•	Percentage
•	Grade
3.	Enter Data: Enter the names of students, their roll numbers, and the marks obtained in each subject in the corresponding cells.
4.	Calculate Total Marks: In the Total Marks column, use a formula to sum up the marks obtained in all subjects for each student. For example, if your subjects' marks are in columns B to E, and the total marks column is F, you can use the formula =SUM(B2:E2) in cell F2 and drag it down to apply to all students.
5.	Calculate Percentage: In the Percentage column, use a formula to calculate the percentage obtained by each student. For example, if the total marks are in column F and you want the percentage in column G, you can use the formula =(F2/TotalMarks)*100 in cell G2 (assuming 'TotalMarks' refers to the total marks obtained by each student).
6.	Assign Grades: Depending on your grading system, you can set up criteria for different grades. For example, if you have a grading system where 90% or above is an A, 80-89% is a B, and so on, you can use nested IF statements or VLOOKUP to assign grades based on the percentage obtained.
For More Info Watch This Full Video: How to Make Marksheet In Excel
7.	Formatting: Format your marksheet to make it visually appealing and easier to read. You can add borders, apply cell colors, use bold fonts for headings, etc.
8.	Review and Finalize: Once you have set up your marksheet, review it to ensure accuracy. Check all formulas, especially if you have dragged them across multiple cells.
9.	Print or Share: Once satisfied with your marksheet, you can print it out or share it digitally with others.
Remember, Excel provides a wide range of functionalities for data manipulation and analysis. You can customize your marksheet based on your specific needs and preferences using various Excel functions and features.
Oriole Insights - Decode future trends with social beliefs
Published: 2024-03-22 11:59:39

Oriole Insights is a cutting-edge platform that allows users to tap into the power of collective wisdom to predict future trends and outcomes. By participating in this gamified prediction system, users can not only enhance their reputation and trust but also gain valuable insights into asset trends and events https://app.orioleinsights.io/.

The platform utilizes social beliefs and user input to generate accurate predictions, making it a valuable tool for anyone looking to stay ahead of the curve in various industries. Whether you're a seasoned investor or simply curious about what the future holds, Oriole Insights offers a unique opportunity to decode future trends and make informed decisions.
Master JavaScript Variables: Declare, Initialize, Types, and Naming Secrets!
Tags: webdev, beginners, javascript, tutorial
Published: 2024-03-22 11:56:25

Thrilled to share my latest video with you all! 🌐🚀 "Unleash Your Code: JavaScript Variables Demystified!" is now live on my YouTube channel, where I break down the essentials of JavaScript variables.If you're ready to enhance your JavaScript skills and write more efficient code, click on the link and get watching now! Don't forget to like, share, and subscribe for more web development wisdom.
[Video Link](https://youtu.be/1SAMgENFe3k?si=ITIzRBXMD2bv_cB7)

Happy coding! #JavaScript #WebDevelopment #CodingTutorial #FullStackDeveloper #FrontEnd #LearningToCode #CodeNewbies #TechCommunity
Grafana Dashboard For AWS Billing Monitor
Tags: grafana, aws, billing, monitoring
Published: 2024-03-22 11:44:52

To view the Grafana Dashboard

```
https://neupanekrishna33.grafana.net/public-dashboards/4528181834b54b41bc54e09e952f5467
```

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/stwtckn7o3wixr5hribx.png)
_sample dashboard with no data _

**To Import the dashboard from ID: 20754**
**To import a dashboard, follow these steps:**

1. Click Dashboards in the Primary Menu.
2. Click New and select Import in the drop-down Menu.
3. Perform On of the Following Steps:

a. Upload a Dashboard JSON file from my Git:

```
https://github.com/krishna-commits/grafana-dashboard/blob/main/20754_rev1.json
```
b. Or Paste a Grafana ID 20754 into the field Provided.
c. Paste dashboard JSON text directly into the text area

4. Select a data source, if required.
5. Click Import
6. Save a dashboard

**Hope you guys will enjoy this dashboard.**
Informatica Cloud Application Integration | Informatica Online Training
Tags: informaticacloudtraining, cloudlearning, cloudtechnology
Published: 2024-03-22 11:31:19


Visualpath provides a Informatica Cloud Online Training  with complete real-time based Training by Real Time Experts with free Informatica Cloud Interview Questions and Recorded Videos. Avail to complete Informatica Training in Hyderabad, USA, Canada, UK Australia. Enroll Now for FREE DEMO. Call on +91-9989971070. 	
WhatsApp: https://www.whatsapp.com/catalog/919989971070/
Visit: https://www.visualpath.in/informatica-cloud-training.html


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/clr5w053co7llquj2z1o.jpg)
Hyva Theme Development: Building Blazing-Fast Magento Experiences
Tags: hyvathemedevelopment, hyvathemetemplate
Published: 2024-03-22 11:29:04

Magento stores are known for their power and flexibility, but sometimes that power comes at the cost of speed. Traditional Magento themes can be weighed down by bulky code, leading to sluggish load times and a frustrating user experience.

This is where Hyva theme development steps in. Hyva offers a whole new approach to Magento frontend development, built for speed and performance. If you're a developer looking to create high-performing Magento stores, here's why Hyva theme development should be on your radar.

## **Hyva: A Modern Tech Stack for Modern Stores**

Hyva themes ditch the traditional Magento approach and leverage a modern tech stack for lightning-fast performance. Here's what makes Hyva development unique:

- **Tailwind CSS:**
Hyva utilizes Tailwind's utility-first approach, giving you complete control over your store's design without writing a ton of custom CSS.

- **Alpine.js:** 
This lightweight JavaScript framework allows you to add interactivity to your theme without introducing bloat.

- **React (optional)**:
 For more complex functionalities, Hyva integrates seamlessly with 
 React, allowing you to build custom components.

- **GraphQL:** 
Hyva leverages Magento's robust GraphQL API for efficient data fetching, ensuring your pages load quickly.

## **Benefits of Hyva Theme Development**

Here's what makes Hyva theme development an attractive option for developers and store owners alike:

- **Unmatched Performance:**
Hyva stores are blazing fast, leading to happier customers and better conversions.

- **Simplified Development:** 
The modern tech stack makes development quicker and more efficient.

- **Clean and Maintainable Code:** 
Hyva promotes a component-based approach, resulting in cleaner and easier-to-maintain codebases.

- **Future-Proof Technology:**
Hyva leverages modern technologies that are constantly evolving, ensuring your store stays ahead of the curve.

[Hyva theme development](https://aureatelabs.com/services/hyva-theme-ready-templates/) offers a powerful and efficient way to build high-performing Magento stores. With its focus on speed, clean code, and modern technologies, Hyva is the future of Magento frontend development. So, are you ready to build the next generation of Magento experiences?
Top Web Development Trends April 2024
Tags: webdev, programming, tutorial, productivity
Published: 2024-03-22 11:23:09


As we are heading towards April 2024, there are several web development trends. Whether it is a personalized website or a professional application, these trends will help you out in delivering the maximum output. Traditional web development are escaping slowly because they are not in demand. Thanks, to robust [web hosting](https://www.milesweb.in/?utm_source=Devto-InternalLinking&utm_medium=Devto-Article&utm_campaign=Sommaya-DevToForum-PHPHostingForumBlog-110324) infrastructure and advanced technologies that evolved web apps. 

Because of the tech advancement, the kind of website development and its web hosting operation is scaling exponentially. There is a rise of different framework and IT resources that will create the buzz throughout the year. Read on.

### Web 3.0
Web 3.0 is no more a theoretical concept about website development. One of the major example of it is decentralization. This paradigm shift show how an information is distributed and accessed on the web. This shift is evident in the growing prevalence of decentralized applications (DApps), which promise to bring about more secure, transparent, and user-centric online experiences. 

### Blockchain Technology
It is not just about the cryptocurrency, but also in website development Blockchain is playing a crucial role. This tech advancement offers new ways to ensure data integrity, security, and transparency in web applications.

### Docker and Kubernetes Tool
By 2024, containerization and orchestration tools such as Docker and Kubernetes will be more sophisticated and easier to use. Especially in microservices architectures, they play a crucial role in deploying and managing applications. Scaling applications seamlessly, managing updates without downtime, and ensuring consistency across various development, testing, and production environments are all advantages of these tools.
Human-Machine Collaboration: Sage AI Strives to Build Internet Content Production Infrastructure
Tags: ai, productivity, discuss, news
Published: 2024-03-22 11:18:34

Original content production, especially creative work, has always been considered a domain exclusive to humans and a manifestation of intelligence. Today, AI is making significant strides in digital content production. The strong demand for digital content, the trend towards video, and creativity-driven developments are shaping a new era of the internet. As the world’s first AI and big data-driven Web3 community creation platform, Sage AI aspires to become the infrastructure for future internet content production, committed to assisting users in the creative generation of digital content through human-machine collaboration.

In this new era, Sage AI has gradually integrated deeply into producing various media forms, including text, code, music, images, videos, and 3D. Sage AI can serve as a diverse assistant in news writing, academic paper and novel composition, music composition and arrangement, artistry in various styles, video editing and post-production engineering, and 3D modelling. Furthermore, it can accomplish the creation, editing, and style transfer of content on specific topics under human guidance.

Sage AI has initially achieved satisfying results in text, voice, and image generation based on natural language, especially in creating highly stylized images like knowledge-based short articles and illustrations. Although still exploring more complex media like video and 3D, the Sage AI project is continuously striving to enhance technology to meet these challenges and looks forward to achieving more significant breakthroughs in the future.

Methodologically, the multimodal processing of AIGC across text, image, video, and 3D has become a hotspot. The Sage AI project is keeping pace with this trend by leveraging its powerful artificial intelligence technology to enable conversions and mappings across various modalities. For instance, Sage AI can perform text-to-speech and text-to-image generation applications, offering users a more diverse and innovative content creation experience.

With its leading AI and big data technology, Sage AI is becoming the infrastructure for digital content production, providing users with more efficient and innovative content generation tools and driving the development and progress of internet content creation. As Sage AI technology continues to improve and application scenarios expand, it will bring more possibilities to digital content production and inject new vitality into the flourishing of internet culture.
Unable to upgrade from angular version 14 to 17
Tags: angular
Published: 2024-03-22 11:04:55

Hi,

We are trying to upgrade form angular version from 14 to 17 following the steps in the below url.
https://update.angular.io/?v=14.0-17.0

It gave error related to schematic dependency so used the below line to upgrade to 15 and 16.
ng update @angular/core@16 @angular/cli@16 @angular-eslint/schematics@16
ng update @angular/core@16 @angular/cli@16 @angular-eslint/schematics@16

after upgrading to 15, when build the code it worked. Later after upgrading to 16 when build the code it failed. 

When ran ng version command, noticed @angular.cdk and @angular/material version are still shown as 14 and are not upgraded. 
So upgraded these 2 to version 15 and 16 using the below commands
ng update @angular/material@15 @angular/cdk@15
ng update @angular/material@16 @angular/cdk@16

Built the code got the below error. Any idea how this can be fixed.
 node_modules/ng2-dragula/dist/components/dragula.module.d.ts:3:23 - error TS2314: Generic type 'ModuleWithProviders<T>' requires 1 type argument
Please note tried multiple times by removing the node_modules and rolling back package.json and re-ran upgrade, but encountering the same issue.
Any idea what is the problem here.

Thanks,
Sunanda.
Wizio Bundle: Quantity Breaks is the best product bundle app for Shopify.
Tags: shopifybundleapp, productbundleappshopify, shopifybundleproducts
Published: 2024-03-22 11:02:30

Take your store to the next level with Wizio's extensive list of features designed to help you convert more visitors into happy customers, such as upsells and bundles, FBT bundles, cat drawer bundles, BOGO, volume discounts, and more. The best [Shopify bundle app](https://wizio.app/wizio-bundle-quantity-breaks-app-for-shopify)

Utilize these tools to boost and unlock your store's full potential quickly and easily.

Add app now: https://apps.shopify.com/wizio-product-bundle-upsell
Vscode black formatter
Published: 2024-03-22 10:57:36

Assumptions:

- python extension is installed on vscode [python extension](https://marketplace.visualstudio.com/items?itemName=tht13.python)
- balck formatter extension is installed on vscode [balck formatter extension](https://marketplace.visualstudio.com/items?itemName=ms-python.black-formatter&ssr=false#review-details)


1. CTRL + SHIFT + p (opens the command pallet)
2. type settings.json (opens user settings)
3. set as a default formatter the black formater and max line length to 120

```json
{
    "[python]": {
    "editor.defaultFormatter": "ms-python.black-formatter",
    },
    "black-formatter.args": ["--line-length", "120"]
}
```
Coding for kids
Tags: coding, for, kid
Published: 2024-03-22 10:57:18

Shard Center for Innovation is an esteemed institution dedicated to nurturing young minds through **[coding for kids](https://scilindia.org/blog/coding-for-kids/)** programs. With a strong focus on technological literacy and creativity, our courses are designed to equip children aged 7 to 17 with essential coding skills in a fun and engaging way.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9kqa062nnyogxntxpcnb.jpg)

Our curriculum is carefully crafted to cater to different age groups and skill levels, ensuring that each child receives personalized attention and support. Through hands-on projects, interactive activities, and collaborative learning environments, we inspire curiosity and foster a passion for coding early on.

At Shard Center for Innovation, we believe that coding is a fundamental skill for the future. It not only develops logical thinking and problem-solving abilities but also encourages innovation and entrepreneurship. By empowering children with coding knowledge, we prepare them for the digital age and open doors to limitless opportunities.

Our experienced instructors are dedicated to providing high-quality education, and our state-of-the-art facilities create an optimal learning environment. Whether your child is a beginner or an advanced coder, our programs offer a progressive learning journey that builds confidence and unlocks their full potential.

Join us at Shard Center for Innovation and embark on a transformative coding adventure that will shape your child's future!

Visit for Innovation
For more information, call: +91 8178078112
Mail: info@scilindia.org
Visit us at: www.scilindia.org
Fastest Way to Design an Ecommerce Website Using WordPress
Tags: webdev
Published: 2024-03-22 10:50:26

In today's digital age, having a quality and effective ecommerce website is essential for any business looking to expand its online presence. WordPress has become one of the most popular platforms for building ecommerce websites, with its flexibility and user-friendly interface. Here are some simple steps to design an ecommerce website using WordPress quickly:

Choose a Theme: The first step is to select a suitable ecommerce theme. WordPress offers many themes optimized for online stores. Choose a theme that fits your business niche and has the features you need.

Install WooCommerce Plugin: WooCommerce is a powerful WordPress plugin that turns your website into a complete online store. Once installed and activated, WooCommerce allows you to manage products, orders, payments, and shipping easily.

Add Products: Start by adding the products you want to sell to your store. For each product, provide detailed information, high-quality images, and reasonable prices to attract customers.

Customize and Configure: Customize the appearance of your website to reflect your brand. Add your logo, colors, fonts, and other design elements to create an engaging and professional online shopping experience.

Integrate Payment and Shipping Methods: WooCommerce supports various payment and shipping methods. Configure these settings to suit your business needs and provide the most convenient options for customers when shopping on your website.

Test and Debug: Before launching your website, thoroughly test it to ensure that all functions work correctly. Check features such as shopping, payment, and shipping to ensure that no errors occur.

Optimize for Speed: Optimizing your website to improve page loading speed is crucial. Use tools like image optimization plugins, caching, and Content Delivery Networks (CDNs) to reduce page load times and enhance user experience.

Promote and Market: Once your website is deployed, start promoting and marketing to attract customers. Use social media channels, email marketing, and Search Engine Optimization (SEO) to reach your target audience and drive traffic to your products.

With the above steps, you can quickly design a quality and effective ecommerce website using WordPress, helping you successfully grow your online business.
[7F Garden
](https://7fgarden.com/)