<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Timi</title>
    <description>The latest articles on DEV Community by Timi (@timidev).</description>
    <link>https://dev.to/timidev</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1094435%2F82b696ec-1057-4755-bcc6-002a08542e2f.png</url>
      <title>DEV Community: Timi</title>
      <link>https://dev.to/timidev</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/timidev"/>
    <language>en</language>
    <item>
      <title>Programming Acronyms You Need To Know</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Mon, 10 Jun 2024 11:15:23 +0000</pubDate>
      <link>https://dev.to/timidev/programming-acronyms-you-need-to-know-2ibm</link>
      <guid>https://dev.to/timidev/programming-acronyms-you-need-to-know-2ibm</guid>
      <description>&lt;p&gt;In Programming, we have many acronyms that we use daily, and It can be hard to memorize all of them in your head. Sometimes we even tend to forget the simple ones. It’ll be fun if you have a list of these acronyms you can return to once in a while as a refresher, so here is a list of Programming Acronyms you need to know.&lt;/p&gt;

&lt;h3&gt;
  
  
  Web Development
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;HTML: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/HTML#:~:text=Hypertext%20Markup%20Language%20(HTML)%20is,scripting%20languages%20such%20as%20JavaScript."&gt;HyperText Markup Language&lt;/a&gt;. It is the standard markup language for documents designed to be displayed in a web browser.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;CSS: Abbreviation of &lt;a href="https://www.w3.org/Style/CSS/Overview.en.html"&gt;Cascading Style Sheets&lt;/a&gt;. CSS is a style sheet language used for describing the presentation of a document written in HTML.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;JS: Abbreviation of &lt;a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript"&gt;JavaScript&lt;/a&gt;. JavaScript is the main programming language of the Web.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;ES: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/ECMAScript#:~:text=ECMAScript%20(or%20ES)%20is%20a,pages%20across%20different%20Web%20browsers."&gt;ECMAScript&lt;/a&gt;. ECMAScript (or ES) is a general-purpose programming language initially designed to be a Web scripting language.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;DOM: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Document_Object_Model#:~:text=The%20Document%20Object%20Model%20"&gt;Document Object Model&lt;/a&gt;. The Document Object Model or DOM is a programming interface for HTML and XML documents.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;XML: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/XML#:~:text=Extensible%20Markup%20Language%20(XML)%20is,free%20open%20standards%E2%80%94define%20XML."&gt;eXtensible Markup Language&lt;/a&gt;. XML is a markup language designed by the World Wide Web Consortium (W3C) to establish a syntax for encoding documents that both machines and humans could read.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;AJAX: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Ajax_(programming)"&gt;Asynchronous JavaScript And XML&lt;/a&gt;. Ajax is a set of techniques using web technologies on the client side to create asynchronous communication in web applications.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;JSON: Abbreviation of &lt;a href="https://www.json.org/json-en.html"&gt;JavaScript Object Notation&lt;/a&gt;. It is a data-interchange format.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;IIFE: Abbreviation of &lt;a href="https://developer.mozilla.org/en-US/docs/Glossary/IIFE#:~:text=An%20IIFE%20"&gt;Immediately invoked function expression&lt;/a&gt;. An IIFE is a JavaScript function that runs as soon as it is defined.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;REST: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Representational_state_transfer"&gt;Representational state transfer&lt;/a&gt;. REST defines a programming architectural style that provides standards for communication between computer systems.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;SMACSS: Abbreviation of &lt;a href="https://swapps.com/blog/what-is-smacss-and-how-to-use-it/"&gt;Scalable and Modular Architecture for CSS&lt;/a&gt;. SMACSS is a style guide based on five categories (base, layout, module, state, and theme).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;SEO: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Search_engine_optimization"&gt;Search Engine Optimization&lt;/a&gt;. The SEO Abbreviation is used to define the process of improving the quality and quantity of website traffic by increasing the visibility of a website.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;UX: Abbreviation of &lt;a href="https://www.interaction-design.org/literature/topics/ux-design"&gt;User Experience&lt;/a&gt;. UX abbreviation is used to define the design process to create products that provide meaningful and proper experiences to users.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;CDN: Abbreviation of &lt;a href="https://www.cloudflare.com/learning/cdn/what-is-a-cdn/"&gt;Content delivery network&lt;/a&gt;. A CDN is highly distributed servers that help minimize delays in loading web page content by reducing the physical distance between the server and the user.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;CMS: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Content_management_system"&gt;Content management system&lt;/a&gt;. A CMS is a software application used for creating and maintaining digital content.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;




&lt;h3&gt;
  
  
  Software Development and Programming
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;IDE: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Integrated_development_environment#:~:text=An%20integrated%20development%20environment%20"&gt;Integrated Development Environment&lt;/a&gt;. An IDE is a software application that provides facilities to programmers for software development.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;API Abbreviation of &lt;a href="https://www.freecodecamp.org/news/what-is-an-api-in-english-please-b880a3214a82/"&gt;Application Programming Interface&lt;/a&gt;. An API enables two different applications to talk with each other to make some parts of the code available.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;SDK: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Software_development_kit#:~:text=A%20software%20development%20kit%20"&gt;Software development kit&lt;/a&gt;. An SDK is a collection of software development tools in one installable package.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;JDK: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Java_Development_Kit"&gt;Java Development Kit&lt;/a&gt;. A JDK is an implementation of the Java Platform.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;JRE: Abbreviation of &lt;a href="https://www.infoworld.com/article/3304858/what-is-the-jre-introduction-to-the-java-runtime-environment.html"&gt;Java Runtime Environment&lt;/a&gt;. It is the part of the JDK that contains and organizes the set of tools and minimum requirements for executing Java applications.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;JVM: Abbreviation of &lt;a href="https://www.guru99.com/java-virtual-machine-jvm.html#:~:text=Java%20Virtual%20Machine%20(JVM)%20is,code%20for%20a%20particular%20system."&gt;Java Virtual Machine&lt;/a&gt;. The JVM is the virtual machine that allows computers to run Java programs as well as programs written in other languages that are also compiled into Java bytecode.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;SOAP: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/SOAP"&gt;Simple Object Access Protocol&lt;/a&gt;. SOAP is used to define a messaging protocol specification for exchanging structured information by web services.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;SQL: Abbreviation of &lt;a href="https://www.webopedia.com/TERM/S/SQL.html"&gt;Structured Query Language&lt;/a&gt;. The SQL language is used in programming for managing data in a relational database.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;JDBC: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Java_Database_Connectivity#:~:text=Java%20Database%20Connectivity%20(JDBC)%20is,Edition%20platform%2C%20from%20Oracle%20Corporation."&gt;Java Database Connectivity&lt;/a&gt;. JDBC is an API for the Java language which defines how a client may access a database.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;ORM: Abbreviation of &lt;a href="https://searchapparchitecture.techtarget.com/definition/object-oriented-programming-OOP#:~:text=Object%2Doriented%20programming%20(OOP)%20is%20a%20computer%20programming%20model,has%20unique%20attributes%20and%20behavior."&gt;Object Relational Mapping&lt;/a&gt;. An ORM is a programming technique used for converting data between incompatible systems using object-oriented programming languages.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;OOP: Abbreviation of &lt;a href="https://searchapparchitecture.techtarget.com/definition/object-oriented-programming-OOP#:~:text=Object%2Doriented%20programming%20(OOP)%20is%20a%20computer%20programming%20model,has%20unique%20attributes%20and%20behavior."&gt;Object-oriented programming&lt;/a&gt;. OOP is a programming paradigm based on the notion of objects.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;TDD: Abbreviation of &lt;a href="https://technologyconversations.com/2013/12/20/test-driven-development-tdd-example-walkthrough/#:~:text=Test%2Ddriven%20development%20(TDD),to%20pass%20that%20test%2C%20and"&gt;Test-driven development&lt;/a&gt;. TDD is a software development process that is based on the repetition of a short development cycle: requirements are turned into specific test cases, and then the code is fixed so that the tests pass.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;BDD: Abbreviation of &lt;a href="https://medium.com/javascript-scene/behavior-driven-development-bdd-and-functional-testing-62084ad7f1f2"&gt;Behavior-driven development&lt;/a&gt;. BDD is a behavioral-driven development strategy, that has evolved from TDD, but it is not a testing technique. BDD defines a common language among all stakeholders and developers.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;XP: Abbreviation of &lt;a href="https://www.agilealliance.org/glossary/xp/#:~:text=Extreme%20Programming%20(XP)%20is%20an,engineering%20practices%20for%20software%20development."&gt;Extreme Programming&lt;/a&gt;. XP is a software development method that organizes people to produce higher-quality software more productively and tries to reduce the cost of changes in requirements by having several short development cycles.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;UAT: Abbreviation of &lt;a href="https://www.guru99.com/user-acceptance-testing.html"&gt;User Acceptance Testing&lt;/a&gt;. UAT is the last phase of the software testing process&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;YAGNI: Abbreviation of &lt;a href="https://www.martinfowler.com/bliki/Yagni.html"&gt;You Ain't Gonna Need It&lt;/a&gt;. YAGNI is a principle of XP that states that a programmer should not add functionality until deemed necessary.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;GNU: This is a recursive acronym for &lt;a href="https://www.gnu.org/home.en.html"&gt;“GNU's Not Unix&lt;/a&gt;. GNU is an extensive collection of free software, which gave rise to the family of operating systems popularly known as Linux.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;SOLID: Abbreviation of &lt;a href="https://medium.com/backticks-tildes/the-s-o-l-i-d-principles-in-pictures-b34ce2f1e898"&gt;Single responsibility principle, Open-closed principle, Liskov substitution principle, Interface segregation principle, and Dependency inversion principle&lt;/a&gt;. SOLID is a mnemonic acronym for five design principles designed to make software designs more flexible, understandable, and maintainable.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;REGEX: Abbreviation of &lt;a href="https://regexr.com/"&gt;Regular expression&lt;/a&gt;. A REGEX is a regular expression of a sequence of characters that define a search pattern.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;




&lt;h3&gt;
  
  
  Data and File Management
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;CSV: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Comma-separated_values"&gt;Comma-separated values&lt;/a&gt;. A CSV file is a delimited text file that uses a comma to separate values.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;ETL: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Extract,_transform,_load"&gt;Extract, Transform, Load&lt;/a&gt;. The ETL abbreviation is used to define a type of data integration that refers to the three steps (extract, transform, load) used to mix data from multiple sources.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;CRUD: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Create,_read,_update_and_delete"&gt;Create, read, update, and delete&lt;/a&gt;. In programming, create, read, edit, and delete are the four essential functions of data manipulation.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;EOF: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/EOF"&gt;End of File&lt;/a&gt;. The EOF abbreviation is used to indicate the end of a file.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;AVIF: Abbreviation of &lt;a href="https://aomediacodec.github.io/av1-avif/"&gt;AV1 Image File Format&lt;/a&gt;. It is a new, highly efficient image compression format.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;




&lt;h3&gt;
  
  
  System and Architecture
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;MVC: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93controller"&gt;Model, View, and Controller&lt;/a&gt;. MVC abbreviation is used to define a software design pattern commonly used for developing user interfaces that distribute the program logic into three elements.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;ERP: Abbreviation of &lt;a href="https://www.netsuite.com/portal/resource/articles/erp/what-is-erp.shtml"&gt;Enterprise resource planning&lt;/a&gt;. ERP abbreviation is used to refer to a sort of software that organizations use to manage day-to-day business activities.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;FIFO: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/FIFO_(computing_and_electronics)"&gt;First In First Out&lt;/a&gt;. The FIFO abbreviation is used to indicate that the first item is the first item out in a queue.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;FTP: Abbreviation of &lt;a href="https://www.digitaltrends.com/computing/what-is-ftp-and-how-do-i-use-it/"&gt;File Transfer Protocol&lt;/a&gt;. The FTP abbreviation is used to refer to a protocol widely used to transfer files between computers.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;AD: Abbreviation of &lt;a href="https://searchwindowsserver.techtarget.com/definition/Active-Directory#:~:text=Active%20Directory%20(AD)%20is%20Microsoft%27s,device%2C%20such%20as%20a%20printer."&gt;Active Directory&lt;/a&gt;. AD is Microsoft's proprietary directory service.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;SAAS: Abbreviation of &lt;a href="https://www.salesforce.com/eu/learning-centre/tech/saas/"&gt;Software as a Service&lt;/a&gt;. SaaS is a software solution that is purchased from a cloud service provider on a pay-per-use model.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;




&lt;h3&gt;
  
  
  Time and Identification
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;UTC: Abbreviation of &lt;a href="https://www.timeanddate.com/worldclock/timezone/utc"&gt;Coordinated Universal Time&lt;/a&gt;. UTC is the primary time standard by which the world regulates clocks and time.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;UUID: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Universally_unique_identifier"&gt;Universally unique identifier&lt;/a&gt;. A UUID is a 128-bit number used to identify information in computer systems.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;




&lt;h3&gt;
  
  
  User Interface
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;GUI: Abbreviation of &lt;a href="https://www.computerhope.com/jargon/g/gui.htm#:~:text=A%20GUI%20(graphical%20user%20interface)%20is%20a%20system%20of%20interactive,the%20user%20interacts%20with%20them."&gt;Graphic User Interface&lt;/a&gt;. A GUI or graphical user interface is a form of user interface that allows users to interact with electronic devices through a graphical interface.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;WYSIWYG: Abbreviation of &lt;a href="https://www.zesty.io/mindshare/marketing-technology/what-is-wysiwyg-what-you-see-is-what-you-get/"&gt;What you see is what you get&lt;/a&gt;. Microsoft Word is a common example to define a WYSIWYG editor. You have a blank page with some format tools, words, images, tables, and so forth. What you see on the screen is exactly what you see when you print the document.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;




&lt;h3&gt;
  
  
  Version Control
&lt;/h3&gt;

&lt;p&gt;CVS: Abbreviation of &lt;a href="https://en.wikipedia.org/wiki/Concurrent_Versions_System"&gt;Concurrent Versioning System&lt;/a&gt;. CVS is a version control system that tracks all changes in a set of files.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Make sure to take the time to read this, and remember you can’t just force all these acronyms into your head in one night, It’s okay to not know it all.&lt;/p&gt;

&lt;p&gt;If you enjoyed this post, make sure to follow me on &lt;a href="//x.com/timi_networks"&gt;Twitter&lt;/a&gt;&lt;/p&gt;

</description>
      <category>programming</category>
      <category>acronyms</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Why I switched to the Web</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Wed, 22 Nov 2023 02:11:46 +0000</pubDate>
      <link>https://dev.to/timidev/why-i-switched-to-the-web-4d19</link>
      <guid>https://dev.to/timidev/why-i-switched-to-the-web-4d19</guid>
      <description>&lt;h2&gt;
  
  
  Exploring the Shift: From Web to Mobile Development
&lt;/h2&gt;

&lt;p&gt;In the ever-evolving world of technology, the debate between web and mobile apps remains ongoing. Although both have their unique benefits, I feel the need to explain why I find the web particularly appealing before discussing my shift to mobile development.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why Embrace the Web Over Mobile Apps?
&lt;/h3&gt;

&lt;p&gt;The Internet has a unique appeal and usefulness, and it excels in several ways:&lt;/p&gt;

&lt;h4&gt;
  
  
  Accessibility:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Cross-Platform Compatibility&lt;/strong&gt;: Websites seamlessly adapt across devices—laptops, tablets, and smartphones—eliminating the need for multiple versions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Instant Accessibility&lt;/strong&gt;: A mere click grants access to web content, eliminating downloads and preserving device space and time.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Cost-Effectiveness:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Development and Maintenance&lt;/strong&gt;: Creating and updating websites often incurs lower costs compared to the complexities and frequent updates associated with app development.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Effortless Updates&lt;/strong&gt;: Web updates occur instantly, sparing users from the hassle of downloading new versions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Discoverability and Shareability:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Search Engine Visibility&lt;/strong&gt;: Web content is easily discoverable via search engines, ensuring a wider audience reach.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Effortless Sharing&lt;/strong&gt;: Sharing web content is seamless, enabling rapid dissemination and potential virality.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Flexibility and Reach:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Real-Time Updates&lt;/strong&gt;: Web content updates swiftly, ensuring the dissemination of real-time information.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Wider Audience Reach&lt;/strong&gt;: With no installation barriers, websites effortlessly reach a broader audience.&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  Transitioning: Why Mobile Development?
&lt;/h3&gt;

&lt;p&gt;The shift from web to mobile development involves distinctive learning curves. While HTML and CSS lay the foundation for web development, mobile development encompasses languages like &lt;code&gt;Java&lt;/code&gt;, &lt;code&gt;C&lt;/code&gt;, &lt;code&gt;C++&lt;/code&gt;, &lt;code&gt;Flutter[Dart]&lt;/code&gt;, and &lt;code&gt;React Native&lt;/code&gt;. However, the learning curve wasn’t the primary reason for my transition.&lt;/p&gt;




&lt;h3&gt;
  
  
  Maintenance: Web vs. Mobile Apps
&lt;/h3&gt;

&lt;p&gt;Maintaining both web and mobile apps is crucial, primarily focusing on the user experience. Mobile development, however, presents a significant challenge: &lt;strong&gt;Updates&lt;/strong&gt;.&lt;/p&gt;

&lt;h4&gt;
  
  
  Updates:
&lt;/h4&gt;

&lt;p&gt;Updating mobile apps involves waiting for verification from app stores, often leading to delayed updates and potential user inconvenience.&lt;/p&gt;

&lt;h4&gt;
  
  
  Rollbacks:
&lt;/h4&gt;

&lt;p&gt;Web apps, supported by tools like &lt;code&gt;Git&lt;/code&gt; and platforms like Vercel, allow for a swift rollback of changes compared to mobile apps, making the process more manageable.&lt;/p&gt;




&lt;h3&gt;
  
  
  Comparison: Web vs. Mobile App Maintenance
&lt;/h3&gt;

&lt;h4&gt;
  
  
  Web Maintenance:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Seamless Updates&lt;/strong&gt;: Websites offer immediate updates without necessitating users to download new versions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cost Efficiency&lt;/strong&gt;: Maintaining websites is generally cost-effective due to simpler update processes and fewer platform-specific demands.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Consistent Cross-Platform Experience&lt;/strong&gt;: Websites maintain a consistent look and function across various devices, reducing the need for device-specific maintenance.&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;
  
  
  Mobile App Maintenance:
&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Frequent Updates&lt;/strong&gt;: Mobile apps demand frequent updates due to evolving OS requirements, new features, or security patches.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Platform-Specific Needs&lt;/strong&gt;: Catering to different operating systems necessitates tailored updates for each platform.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;User Engagement Challenges&lt;/strong&gt;: Encouraging regular app updates poses challenges, potentially leading to fragmented user bases.&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  User Experience Consideration:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Impact of Outdated Apps&lt;/strong&gt;: Older app versions might cause compatibility issues, glitches, or security vulnerabilities, adversely affecting the user experience.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Resource Intensiveness&lt;/strong&gt;: Maintaining mobile apps often requires more time, effort, and budget compared to websites.&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  Conclusion:
&lt;/h3&gt;

&lt;p&gt;To summarize, the web offers unparalleled accessibility, cost-effectiveness, and a broader reach, which is why it's a preferred choice for many businesses and users. While mobile apps have their unique appeal, the web's simplicity and adaptability continue to hold a distinctive place in the digital landscape.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>webdev</category>
      <category>frontend</category>
    </item>
    <item>
      <title>Choosing your Database</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Tue, 14 Nov 2023 09:16:21 +0000</pubDate>
      <link>https://dev.to/timidev/choosing-your-database-60g</link>
      <guid>https://dev.to/timidev/choosing-your-database-60g</guid>
      <description>&lt;p&gt;In every functioning application, there is a database, whether it is an eCommerce, movie, icon, chat, or health app you would need a database to hold records. Sometimes a database can even be used for the lightest application. But the art of choosing your database is where the role of an engineer comes in. &lt;/p&gt;

&lt;p&gt;Developers often argue and boast about their database, which is fun but knowing your database, with their strengths and weaknesses is what makes you a developer. Today we're going to look at some databases and we will discuss how to choose the right database for your next project, without any further interruptions let's begin.&lt;/p&gt;




&lt;p&gt;First I'd start with what a database is. Google described a database as an organized collection of data or a type of data store based on the use of a database management system. To make you understand it better, a database is a collection of organized data. &lt;/p&gt;

&lt;p&gt;Think of a database as a locker full of records of stuff you love, or your favorite movie.&lt;/p&gt;

&lt;p&gt;Databases are used in every application you use on a daily basis. Imagine clicking on save to save your file or going to YouTube to watch a video, right? Well without a database all those won't be possible, no 1. You can't save your file without a database, and YouTube can't store billions if not trillions of videos without a database. Okay, we understand what a database is now, let me walk you through choosing the right database for your next application.&lt;/p&gt;




&lt;p&gt;When it comes to picking the right database a lot has to be put into consideration, it takes long planning and engineering work. Let me walk you through a list of plans I made when choosing a database.&lt;/p&gt;




&lt;h2&gt;
  
  
  Understanding Your App's Requirement.
&lt;/h2&gt;

&lt;p&gt;In order to have a database you need to understand your app, ask yourself these four questions&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Would I need to scale this on a daily basis?&lt;/li&gt;
&lt;li&gt;How many users do I have right now?&lt;/li&gt;
&lt;li&gt;How many users would I be expecting for such an app?&lt;/li&gt;
&lt;li&gt;Who is this app for?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Once you're done asking yourself these questions now let's move to the plan.&lt;/p&gt;




&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Database Structure&lt;/strong&gt;: Evaluate the nature of your data. Is it relational or non-relational? MongoDB with its flexibility, is great for non-relational data, while databases like PostgreSQL excel in handling relational data.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Scalability&lt;/strong&gt;: Another thing to consider is the scalability requirements of your app. Will it experience significant growth in users? MongoDB's horizontal scaling makes it a strong contender for applications with scalability demands.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Query Complexity&lt;/strong&gt;: Now consider complex queries... Access the types of queries your app will frequently perform. Some databases, like MySQL, are optimized for complex queries, while others like Redis are designed for quick key-value lookups.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Now that you've understood your app's requirements, there are many more things we need to address like the elephant in the room which is performance. Ah, we all hate it when we open an app or try to perform a search and it takes like up to 4hours to query and retrieve our data. Performance is a great one to look at, so let's address that right now.&lt;/p&gt;




&lt;h2&gt;
  
  
  Performance Metrics
&lt;/h2&gt;

&lt;p&gt;In performance metrics, we have two lists to look at here, which are read and write speeds and latency tolerance. These two keys play a valuable role in a database. Let's dive in.&lt;/p&gt;




&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Read and Write Speeds&lt;/strong&gt;: We all know MongoDB is known for its fast write speeds, making it suitable for write-intensive applications. On the other hand, databases like Redis shine in read-intensive scenarios.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Latency Tolerance&lt;/strong&gt;: If your app requires low-latency data access, you should probably consider databases like Cassandra, designed for distributed, low-latency environments.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Okay, we've dealt with performance metrics, yikes that was some spicy one, but do take time to do your own research and find out everything about your database, we will move on to deployment and maintenance.&lt;/p&gt;




&lt;h2&gt;
  
  
  Development and Maintenance
&lt;/h2&gt;

&lt;p&gt;Is it easy to deploy and maintain, that's a great question you should ask yourself before choosing a database, most databases are even more complex to set up in a production environment than development, while some are very easy, databases like MongoDB, PlanetScale, Redis, ScallaDB, Firebase Firestore, Supabase PostgreSQL database are easy to setup. &lt;/p&gt;

&lt;p&gt;Another thing to put into consideration is, whether is it easy to maintain, what can you do when things start to get rough, when you start experiencing high spikes, and what can you do, you should ask yourself these questions.&lt;/p&gt;




&lt;p&gt;Another important subject to note is to choose a database with a driven and active community, you don't want to choose a database only to find out no one is using it, what then would you do when you face issues, who would you ask questions?&lt;/p&gt;




&lt;h2&gt;
  
  
  Security and Compliance
&lt;/h2&gt;

&lt;p&gt;Always use a secure database, choose a database that is up-to-date with the latest security updates, and so on. Don't say because because of SQL injection is why you are going for NoSQL like MongoDB, The funny thing someone can still exploit a malicious attack on your MongoDB database. Always watch out and keep yourself up to date.&lt;/p&gt;




&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;So yeah that's it, make sure to take your time, and do your research before choosing a database for any application you want to build.&lt;/p&gt;




&lt;h3&gt;
  
  
  Handles
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;getSocials&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;

&lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
   &lt;span class="na"&gt;X&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://twitter.com/timi_networks&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
   &lt;span class="na"&gt;Linkedin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://www.linkedin.com/in/treasure-alekhojie/&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;getSocials&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>javascript</category>
      <category>webdev</category>
      <category>database</category>
    </item>
    <item>
      <title>Authentication is that easy</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Sun, 29 Oct 2023 23:46:13 +0000</pubDate>
      <link>https://dev.to/timidev/authentication-is-that-easy-1e7l</link>
      <guid>https://dev.to/timidev/authentication-is-that-easy-1e7l</guid>
      <description>&lt;p&gt;Authentication is a crucial part of any web application, without authentication anyone of any kind can have access to files, pages, or other items they don't need to have access to, and it's important to get this thing we call authentication right.&lt;/p&gt;

&lt;p&gt;There are so many Authentication platforms or providers as you may call them. Clerk has always been my favorite. Now I'm not usually the one to pick favorites but I've used other providers or platforms, test run them, and use them in production. But there is something I love about Clerk which I will dive into in a moment.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why did I choose Clerk?
&lt;/h2&gt;

&lt;p&gt;What made me fall in love with Clerk is their easy-to-read documentation. I have never seen something very easy to read and understand like this before. The fact that they even support both the &lt;code&gt;app/&lt;/code&gt; dir and the &lt;code&gt;pages/&lt;/code&gt; dir makes it top-notch.&lt;/p&gt;

&lt;h3&gt;
  
  
  Other Alternatives
&lt;/h3&gt;

&lt;p&gt;Yes, Clerk is amazing, but there are so many other great alternatives out there. Now you may not like Clerk, but I believe with every platform comes different alternatives to build on top of. &lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Here are other clerk alternatives you could try&lt;/p&gt;
&lt;/blockquote&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Platform&lt;/th&gt;
&lt;th&gt;Type&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Okta&lt;/td&gt;
&lt;td&gt;Cloud-based&lt;/td&gt;
&lt;td&gt;A cloud-based identity management platform that provides single sign-on, multi-factor authentication, and user provisioning.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Auth0&lt;/td&gt;
&lt;td&gt;Cloud-based&lt;/td&gt;
&lt;td&gt;A cloud-based identity and access management platform that provides authentication, single sign-on, and authorization services.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amazon Cognito&lt;/td&gt;
&lt;td&gt;Cloud-based&lt;/td&gt;
&lt;td&gt;A cloud-based identity management service that provides user registration, authentication, and authorization.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Microsoft Azure Active Directory&lt;/td&gt;
&lt;td&gt;Cloud-based&lt;/td&gt;
&lt;td&gt;A cloud-based identity and access management service that provides single sign-on, multi-factor authentication, and user provisioning.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Firebase Authentication&lt;/td&gt;
&lt;td&gt;Cloud-based&lt;/td&gt;
&lt;td&gt;A cloud-based authentication service that provides user registration, authentication, and authorization.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Supabase&lt;/td&gt;
&lt;td&gt;Cloud-based&lt;/td&gt;
&lt;td&gt;An open-source, Firebase alternative that provides a complete backend platform, including authentication, database, storage, and more.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Authlogic&lt;/td&gt;
&lt;td&gt;Self-hosted&lt;/td&gt;
&lt;td&gt;A self-hosted authentication library for Ruby on Rails.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Devise&lt;/td&gt;
&lt;td&gt;Self-hosted&lt;/td&gt;
&lt;td&gt;A self-hosted authentication library for Ruby on Rails.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Clearance&lt;/td&gt;
&lt;td&gt;Self-hosted&lt;/td&gt;
&lt;td&gt;A self-hosted authentication library for Python.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Warden&lt;/td&gt;
&lt;td&gt;Self-hosted&lt;/td&gt;
&lt;td&gt;A self-hosted authentication library for Ruby on Rails.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Passport&lt;/td&gt;
&lt;td&gt;Self-hosted&lt;/td&gt;
&lt;td&gt;A self-hosted authentication library for Node.js.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Now there are so many other alternatives, but one of these should look familiar to you.&lt;/p&gt;

&lt;h2&gt;
  
  
  Setting up Clerk for Authentication
&lt;/h2&gt;

&lt;p&gt;Now we would look at how to set up Clerk on your Nextjs app.&lt;/p&gt;

&lt;p&gt;Prerequisites&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A Next.js app&lt;/li&gt;
&lt;li&gt;A Clerk account&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Steps:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Install the &lt;code&gt;@clerk/nextjs&lt;/code&gt; package.
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;npm&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="err"&gt;@&lt;/span&gt;&lt;span class="nx"&gt;clerk/nextjs&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  2. Set up your environment keys.
&lt;/h3&gt;

&lt;p&gt;In your Nextjs project's root folder, you need to create a &lt;code&gt;.env.local&lt;/code&gt; file. This is where all your secrets would go.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;pk_test_Z3JlYXQtdGlnZXItOTYuY2xlcmsuYWNjb3VudHMuZGV2JA
&lt;span class="nv"&gt;CLERK_SECRET_KEY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;sk_test_HIqOePkGpnR6QyWVLn3LUsqCsoD1MHEieVdiZXsei2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. Wrap your app in &lt;code&gt;&amp;lt;ClerkProvider /&amp;gt;&lt;/code&gt;
&lt;/h3&gt;

&lt;p&gt;Now you are done adding your environment variables, let's talk about the &lt;code&gt;&amp;lt;ClerkProvider /&amp;gt;&lt;/code&gt; component. This component is important because it makes the Clerk context available to your entire app. First, we would need to import it and then use it.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;App Router: The app/layout.tsx file might be in your src folder if it isn't in your root folder.&lt;br&gt;
&lt;/p&gt;
&lt;/blockquote&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;ClerkProvider&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@clerk/nextjs&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;RootLayout&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="nx"&gt;children&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;}:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;children&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;React&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;ReactNode&lt;/span&gt;
&lt;span class="p"&gt;})&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;ClerkProvider&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;html&lt;/span&gt; &lt;span class="na"&gt;lang&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"en"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;body&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nx"&gt;children&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;body&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;

      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;html&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;ClerkProvider&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We are simply importing the component and mounting it to the RootLayout. This takes control over every element in your Next app, which means even if you route to another page aside from the homepage, the Auth workflow will still take place.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Protecting your app
&lt;/h3&gt;

&lt;p&gt;Now a true authenticated app has lots of protection underneath the hood. In this step, we will cover the requirement of authentication to access this application.&lt;/p&gt;

&lt;p&gt;Now previously we installed Clerk and mounted it to our application. This time we decide which page can be public to the user and which pages are protected. To do so we would need to create a &lt;code&gt;middleware.ts&lt;/code&gt; file. Note you need to be on the app router for this to work properly.&lt;/p&gt;




&lt;p&gt;Create a &lt;code&gt;middleware.ts&lt;/code&gt; file in the root directory of your app.&lt;/p&gt;

&lt;p&gt;Now clerk gave us a wonderful template to use, this template protects our application from every route you create. To add this protection simply copy and paste the following code into your &lt;code&gt;middleware.ts&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;authMiddleware&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;@clerk/nextjs&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// This example protects all routes including api/trpc routes&lt;/span&gt;
&lt;span class="c1"&gt;// Please edit this to allow other routes to be public as needed.&lt;/span&gt;
&lt;span class="c1"&gt;// See https://clerk.com/docs/references/nextjs/auth-middleware for more information about configuring your Middleware&lt;/span&gt;
&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nf"&gt;authMiddleware&lt;/span&gt;&lt;span class="p"&gt;({});&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;config&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;matcher&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;/((?!.+&lt;/span&gt;&lt;span class="se"&gt;\\&lt;/span&gt;&lt;span class="s1"&gt;.[&lt;/span&gt;&lt;span class="se"&gt;\\&lt;/span&gt;&lt;span class="s1"&gt;w]+$|_next).*)&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;/&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;/(api|trpc)(.*)&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now this code is responsible for protecting all routes, including API and TRPC routes, from unauthorized access.&lt;/p&gt;

&lt;h4&gt;
  
  
  Broad Explantation
&lt;/h4&gt;

&lt;p&gt;The &lt;code&gt;authMiddleware&lt;/code&gt; function from &lt;code&gt;@clerk/nextjs&lt;/code&gt; is a pre-configured middleware that authenticates users using Clerk. It takes an options object as a parameter, which can be used to customize its behavior.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;matcher&lt;/code&gt; option in the &lt;code&gt;config&lt;/code&gt; object specifies the routes that the middleware should protect. In this case, the middleware will protect all routes, including API and TRPC routes.&lt;/p&gt;




&lt;h3&gt;
  
  
  5. Building your sign-in and sign-up page
&lt;/h3&gt;

&lt;p&gt;What's an authentication without the sign-in and sign-up page, I mean how else are your users able to access your application?&lt;/p&gt;

&lt;h4&gt;
  
  
  Build your sign-up page
&lt;/h4&gt;

&lt;p&gt;To build the sign-up page in Clerk, we would need a special component, remember when we installed Clerk? Now this package came with a bunch of interesting components we can use. One of them is our own sign-in and sign-up page&lt;/p&gt;

&lt;p&gt;To get started we need to create a new file, this file would be used to render the sign-up page. Think of it like you exporting your Component, with a bunch of functions inside it. Now when Importing that component we also import its functions. This is why It's so interesting.&lt;/p&gt;

&lt;p&gt;If you are using the &lt;code&gt;app/&lt;/code&gt; router the file should look like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;app/sign-up/[[...sign-up]]/page.tsx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;So in brief we created two folders, the &lt;code&gt;sign-up&lt;/code&gt; and &lt;code&gt;[[...sign-up]]&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Now remember in the nextjs &lt;code&gt;app/&lt;/code&gt; router to create a route named /dog. we would do something like this&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;dog/page.tsx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The dog is a folder, and the &lt;code&gt;page.tsx&lt;/code&gt; is the file.&lt;/p&gt;

&lt;p&gt;Now after you have successfully created the two folders with the file for routing, you need to paste the following code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;SignUp&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;@clerk/nextjs&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;Page&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;SignUp&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  Build your sign-in page
&lt;/h4&gt;

&lt;p&gt;Now the only thing we should change here is the folder names, so now it should be &lt;code&gt;sign-in&lt;/code&gt; and &lt;code&gt;[[...sign-in]]&lt;/code&gt;. After that, you can now copy the following code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;SignIn&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;@clerk/nextjs&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;Page&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;SignIn&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h3&gt;
  
  
  6. Updating your environment variables
&lt;/h3&gt;

&lt;p&gt;You might assume that the authentication process is complete and that your routes are functional, but unfortunately, that's not the case. In order for both of these aspects to function properly, we need to make a small adjustment to our environment variables.&lt;/p&gt;

&lt;p&gt;Now we should add environment variables for the &lt;code&gt;signIn&lt;/code&gt;, &lt;code&gt;signUp&lt;/code&gt;, &lt;code&gt;afterSignUp&lt;/code&gt;, and &lt;code&gt;afterSignIn&lt;/code&gt; paths:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;NEXT_PUBLIC_CLERK_SIGN_IN_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;/sign-in
&lt;span class="nv"&gt;NEXT_PUBLIC_CLERK_SIGN_UP_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;/sign-up
&lt;span class="nv"&gt;NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;/
&lt;span class="nv"&gt;NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now let me explain. Remember the routes for &lt;code&gt;sign-in&lt;/code&gt; and &lt;code&gt;sign-up&lt;/code&gt; that we created. Well, we just created it, for Clerk to be able to know which route is our signIn and signUp path we need to specify it.&lt;/p&gt;

&lt;p&gt;We are just basically saying where our route should go for sign-in and signup, and then where it should go after It's finishing signing in and signing up the user.&lt;/p&gt;




&lt;p&gt;Now with these, you have successfully provided Authentication to our Nextjs app. Go build great stuff 🎉&lt;/p&gt;

</description>
      <category>authentication</category>
      <category>nextjs</category>
      <category>clerk</category>
      <category>programming</category>
    </item>
    <item>
      <title>Next.js Caching Rant</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Mon, 21 Aug 2023 11:32:55 +0000</pubDate>
      <link>https://dev.to/timidev/nextjs-caching-rant-k05</link>
      <guid>https://dev.to/timidev/nextjs-caching-rant-k05</guid>
      <description>&lt;p&gt;In the era of React, with the advent of routers, configuring routes within our React applications became a crucial part of our development process. The process seemed simple: set up React routers or other routing mechanisms, and users would be seamlessly directed to the desired pages. However, this approach also introduced some challenges. Notably, when utilizing packages like React Router, users often found themselves frustrated with the frequent re-rendering of DOM elements. It's important to address this issue, which Next.js aimed to solve through caching mechanisms.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Evolution of Routing in React
&lt;/h2&gt;

&lt;p&gt;React Router, a popular routing library for React applications, introduced the concept of routing to different pages within a single-page application. However, this came with a drawback - each navigation caused a re-render of the entire DOM, leading to performance bottlenecks and potential user frustration.&lt;/p&gt;

&lt;h2&gt;
  
  
  Next.js and Caching
&lt;/h2&gt;

&lt;p&gt;Enter Next.js, a framework built on top of React that offers server-side rendering and optimized routing. One of Next.js' standout features is its smart caching mechanism. When you create a new page or layout, Next.js caches the routes you visit, resulting in faster page loads. This aligns with the performance optimization goals of platforms like Vercel, which aim to deliver lightning-fast web experiences.&lt;/p&gt;

&lt;h2&gt;
  
  
  Understanding Next.js Routing
&lt;/h2&gt;

&lt;p&gt;In Next.js, you define new pages within the "pages" directory. For instance:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;pages
|
|
| ____ index.tsx
| ____ example.tsx
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Routing from one page to another becomes a breeze:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;Link&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;next/link&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;Home&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;Link&lt;/span&gt; &lt;span class="nx"&gt;href&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/example&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;&lt;span class="nx"&gt;Go&lt;/span&gt; &lt;span class="nx"&gt;to&lt;/span&gt; &lt;span class="nx"&gt;example&lt;/span&gt; &lt;span class="nx"&gt;page&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="sr"&gt;/Link&lt;/span&gt;&lt;span class="err"&gt;&amp;gt;
&lt;/span&gt;  &lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Data Consistency Challenges
&lt;/h2&gt;

&lt;p&gt;While Next.js' caching strategy significantly improves page load times, it might not be ideal for all scenarios. Consider a dashboard where a user updates a table on the "example" page and then navigates back to the home page. In this case, you might observe that the data on the home page doesn't reflect the recent updates until a full page refresh occurs. This is due to the cached nature of Next.js, and it's crucial to be aware of this behaviour when designing real-time data-driven interfaces.&lt;/p&gt;

&lt;h2&gt;
  
  
  Routing and External Services
&lt;/h2&gt;

&lt;p&gt;Furthermore, when integrating external services like Clerk for Authentication, some quirks can arise. Navigating from one site to another might lead to unexpected behaviour in terms of rendering and authentication. For instance, you might notice delayed rendering or authentication hiccups that require a full refresh to be resolved. This is a consideration when implementing authentication-dependent functionalities in a Next.js application.&lt;/p&gt;

&lt;h2&gt;
  
  
  Tradeoffs
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;One tradeoff is complexity&lt;/strong&gt;. Caching can add complexity to your code, especially if you are caching dynamic data. This is because you need to be careful to invalidate the cache when the data that is being cached changes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Another tradeoff is stale data&lt;/strong&gt;. If you are caching dynamic data, there is a risk that the data in the cache will become stale. This can lead to problems, such as displaying outdated information to users.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Here are some additional tips for using Next.js caching effectively:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Only cache data that is frequently accessed. This will help to reduce the risk of stale data and the cost of caching.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Use a cache invalidation strategy to ensure that the cache is always up-to-date. This can be done manually or automatically.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Use a CDN to cache static assets closer to your users. This will improve the performance of your application for users who are located far from your server.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Monitor your cache performance to ensure that it is working as expected. This will help you to identify any problems and make necessary adjustments to your caching strategy.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Here are some additional considerations for using Next.js caching:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;The type of data you are caching. Some types of data, such as images and CSS files, are more suitable for caching than others, such as the results of a database query.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The frequency of data changes. If the data that you are caching changes frequently, you will need to invalidate the cache more often.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The size of the data. The larger the data that you are caching, the more it will cost to cache it.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The performance requirements of your application. If your application needs to be very responsive, you may need to cache more data than if it does not have such strict performance requirements.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Next.js has significantly advanced the landscape of React applications by addressing performance concerns through caching. While its caching strategy provides remarkable benefits, it's essential to evaluate its suitability for specific use cases, especially those involving real-time data updates and third-party services. By understanding the nuances of routing and caching, developers can create seamless and efficient user experiences while leveraging the power of Next.js and React.&lt;/p&gt;

</description>
      <category>nextjs</category>
      <category>react</category>
      <category>typescript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>My Honest Review of Tailwind, Radix UI, and Shadcn UI</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Tue, 08 Aug 2023 17:47:53 +0000</pubDate>
      <link>https://dev.to/timidev/my-honest-review-of-tailwind-radix-ui-and-shadcn-ui-3ia8</link>
      <guid>https://dev.to/timidev/my-honest-review-of-tailwind-radix-ui-and-shadcn-ui-3ia8</guid>
      <description>&lt;h2&gt;
  
  
  My Honest Review Of These CSS Librarieis
&lt;/h2&gt;

&lt;p&gt;In recent years, there has been a growing trend towards using CSS libraries to speed up and simplify the development of web applications. Three of the most popular CSS libraries today are Tailwind, Radix UI, and Shadcn UI.&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Tailwind&lt;/strong&gt; is a utility-first CSS framework that allows you to build custom styles with a minimal amount of code. It's very popular among developers because it's highly customizable and can be used to create a wide variety of designs. However, Tailwind can be a bit difficult to learn at first, and it can be easy to make mistakes if you're not careful.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Radix UI&lt;/strong&gt; is a component-based CSS library that provides a set of ready-made components that you can use to build your web application. It's a good choice for developers who want to get started quickly without having to worry about writing custom CSS. However, Radix UI can be a bit limiting if you need to create custom components, and it can be more expensive than other CSS libraries.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Shadcn UI&lt;/strong&gt; is a relatively new CSS library that combines the best features of Tailwind and Radix UI. It's highly customizable like Tailwind, but it also provides a set of ready-made components like Radix UI. Shadcn UI is a good choice for developers who want the flexibility of Tailwind with the convenience of a component library.&lt;/p&gt;

&lt;p&gt;Here is a table that summarizes the advantages, disadvantages, and key features of each CSS library:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Tailwind&lt;/th&gt;
&lt;th&gt;Advantages&lt;/th&gt;
&lt;th&gt;Disadvantages&lt;/th&gt;
&lt;th&gt;Key Features&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Tailwind&lt;/td&gt;
&lt;td&gt;Highly customizable, can be used to create a wide variety of designs&lt;/td&gt;
&lt;td&gt;Can be difficult to learn at first, easy to make mistakes&lt;/td&gt;
&lt;td&gt;Utility-first CSS framework, allows you to build custom styles with a minimal amount of code&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Radix UI&lt;/td&gt;
&lt;td&gt;Ready-made components, easy to get started&lt;/td&gt;
&lt;td&gt;Can be limiting if you need to create custom components, more expensive than other CSS libraries&lt;/td&gt;
&lt;td&gt;Component-based CSS library, provides a set of ready-made components that you can use to build your web application&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Shadcn UI&lt;/td&gt;
&lt;td&gt;Highly customizable, ready-made components, easy to learn&lt;/td&gt;
&lt;td&gt;Not as widely used as Tailwind or Radix UI&lt;/td&gt;
&lt;td&gt;Combines the best features of Tailwind and Radix UI, highly customizable, provides a set of ready-made components&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Installation
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Here is a quick overview of how to set up each library:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Tailwind:&lt;/strong&gt; To set up Tailwind, you need to install the &lt;code&gt;tailwindcss&lt;/code&gt; package and the &lt;code&gt;postcss&lt;/code&gt; package. You can do this with the following command:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install &lt;/span&gt;tailwindcss postcss
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once you have installed the packages, you need to create a &lt;code&gt;tailwind.config.js&lt;/code&gt; file in the root directory of your project. This file will contain the configuration settings for Tailwind. You can find more information about the configuration settings in the &lt;a href="https://tailwindcss.com/docs/configuration"&gt;Tailwind documentation&lt;/a&gt;&lt;/p&gt;




&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Radix UI:&lt;/strong&gt; To set up Radix UI, you need to install the &lt;code&gt;radix-ui/themes&lt;/code&gt; package, then any other package that follows. Today I'll show you how to install the followinng&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;radix-ui/themes&lt;/code&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;radix-ui/react-alert-dialog&lt;/code&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Getting Started
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Installation
&lt;/h3&gt;

&lt;h3&gt;
  
  
  1. Install Radix Themes
&lt;/h3&gt;

&lt;p&gt;Install the package from your command line.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;npm&lt;/th&gt;
&lt;th&gt;yarn&lt;/th&gt;
&lt;th&gt;pnpm&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;npm install @radix-ui/themes&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;yarn add @radix-ui/themes&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;pnpm install @radix-ui/themes&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  2. Import the CSS file
&lt;/h3&gt;

&lt;p&gt;Import the global CSS file at the root of your application.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;import &lt;span class="s1"&gt;'@radix-ui/themes/styles.css'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. Add the Theme component
&lt;/h3&gt;

&lt;p&gt;Wrap the root of your application in a &lt;code&gt;Theme&lt;/code&gt; component.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Theme&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@radix-ui/themes&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nf"&gt;function &lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Theme&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;MyApp&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Theme&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  4. Start building
&lt;/h3&gt;

&lt;p&gt;You are now ready to use Radix Themes components.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;Flex&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;Button&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@radix-ui/themes&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;MyApp&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Flex&lt;/span&gt; &lt;span class="na"&gt;direction&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"column"&lt;/span&gt; &lt;span class="na"&gt;gap&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"2"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Hello from Radix Themes :)&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Text&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;Button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Let's go&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;Flex&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Customizing your theme
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://www.radix-ui.com/themes/docs/overview/getting-started#customizing-your-theme"&gt;Learn More&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Installing react-alert-dialog with radix-ui
&lt;/h2&gt;




&lt;h3&gt;
  
  
  Install the Component
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install&lt;/span&gt; @radix-ui/react-dialog 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Usage
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="c1"&gt;//index.tsx&lt;/span&gt;

&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;React&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;react&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="nx"&gt;AlertDialog&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@radix-ui/react-alert-dialog&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;./styles.css&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;AlertDialogDemo&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Root&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Trigger&lt;/span&gt; &lt;span class="na"&gt;asChild&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"Button violet"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Delete account&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Trigger&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Portal&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Overlay&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"AlertDialogOverlay"&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Content&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"AlertDialogContent"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Title&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"AlertDialogTitle"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Are you absolutely sure?&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Title&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Description&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"AlertDialogDescription"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          This action cannot be undone. This will permanently delete your account and remove your
          data from our servers.
        &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Description&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt; &lt;span class="na"&gt;style&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;flex&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;gap&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;25&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;justifyContent&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;flex-end&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Cancel&lt;/span&gt; &lt;span class="na"&gt;asChild&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"Button mauve"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Cancel&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Cancel&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Action&lt;/span&gt; &lt;span class="na"&gt;asChild&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"Button red"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;Yes, delete account&lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Action&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Content&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Portal&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Root&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nx"&gt;AlertDialogDemo&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Using Default CSS
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight css"&gt;&lt;code&gt;
&lt;span class="c"&gt;/* styles.css */&lt;/span&gt;

&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s2"&gt;'@radix-ui/colors/black-alpha.css'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s2"&gt;'@radix-ui/colors/mauve.css'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s2"&gt;'@radix-ui/colors/red.css'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;@import&lt;/span&gt; &lt;span class="s2"&gt;'@radix-ui/colors/violet.css'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c"&gt;/* reset */&lt;/span&gt;
&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;all&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;unset&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.AlertDialogOverlay&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--black-a9&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;fixed&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;inset&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;animation&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;overlayShow&lt;/span&gt; &lt;span class="m"&gt;150ms&lt;/span&gt; &lt;span class="n"&gt;cubic-bezier&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;0.16&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;0.3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.AlertDialogContent&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;white&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;border-radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;6px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;hsl&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;206&lt;/span&gt; &lt;span class="m"&gt;22%&lt;/span&gt; &lt;span class="m"&gt;7%&lt;/span&gt; &lt;span class="p"&gt;/&lt;/span&gt; &lt;span class="m"&gt;35%&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt; &lt;span class="m"&gt;10px&lt;/span&gt; &lt;span class="m"&gt;38px&lt;/span&gt; &lt;span class="m"&gt;-10px&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;hsl&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;206&lt;/span&gt; &lt;span class="m"&gt;22%&lt;/span&gt; &lt;span class="m"&gt;7%&lt;/span&gt; &lt;span class="p"&gt;/&lt;/span&gt; &lt;span class="m"&gt;20%&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt; &lt;span class="m"&gt;10px&lt;/span&gt; &lt;span class="m"&gt;20px&lt;/span&gt; &lt;span class="m"&gt;-15px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;fixed&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;top&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;left&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;translate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;-50%&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;-50%&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;90vw&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;max-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;500px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;max-height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;85vh&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;25px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;animation&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;contentShow&lt;/span&gt; &lt;span class="m"&gt;150ms&lt;/span&gt; &lt;span class="n"&gt;cubic-bezier&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;0.16&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;0.3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.AlertDialogContent&lt;/span&gt;&lt;span class="nd"&gt;:focus&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;outline&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;none&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.AlertDialogTitle&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--mauve-12&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;17px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;font-weight&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;500&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.AlertDialogDescription&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;margin-bottom&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;20px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--mauve-11&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;15px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;line-height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1.5&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nc"&gt;.Button&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;inline-flex&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;align-items&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;justify-content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;center&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;border-radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;4px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;15px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;15px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;line-height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;font-weight&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;500&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;35px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.violet&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;white&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--violet-11&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="m"&gt;10px&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--black-a7&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.violet&lt;/span&gt;&lt;span class="nd"&gt;:hover&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--mauve-3&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.violet&lt;/span&gt;&lt;span class="nd"&gt;:focus&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="no"&gt;black&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.red&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--red-4&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--red-11&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.red&lt;/span&gt;&lt;span class="nd"&gt;:hover&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--red-5&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.red&lt;/span&gt;&lt;span class="nd"&gt;:focus&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--red-7&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.mauve&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--mauve-4&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--mauve-11&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.mauve&lt;/span&gt;&lt;span class="nd"&gt;:hover&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--mauve-5&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nc"&gt;.Button.mauve&lt;/span&gt;&lt;span class="nd"&gt;:focus&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--mauve-7&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;@keyframes&lt;/span&gt; &lt;span class="n"&gt;overlayShow&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nt"&gt;from&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nt"&gt;to&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;@keyframes&lt;/span&gt; &lt;span class="n"&gt;contentShow&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nt"&gt;from&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;translate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;-50%&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;-48%&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;scale&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;0.96&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nt"&gt;to&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;opacity&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;translate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;-50%&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;-50%&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;scale&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Using Component with Tailwind CSS
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;
&lt;span class="c1"&gt;//index.tsx&lt;/span&gt;

&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;React&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;react&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="nx"&gt;AlertDialog&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;@radix-ui/react-alert-dialog&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;AlertDialogDemo&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Root&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Trigger&lt;/span&gt; &lt;span class="na"&gt;asChild&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"text-violet11 hover:bg-mauve3 shadow-blackA7 inline-flex h-[35px] items-center justify-center rounded-[4px] bg-white px-[15px] font-medium leading-none shadow-[0_2px_10px] outline-none focus:shadow-[0_0_0_2px] focus:shadow-black"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        Delete account
      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Trigger&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Portal&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Overlay&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"bg-blackA9 data-[state=open]:animate-overlayShow fixed inset-0"&lt;/span&gt; &lt;span class="p"&gt;/&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Content&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"data-[state=open]:animate-contentShow fixed top-[50%] left-[50%] max-h-[85vh] w-[90vw] max-w-[500px] translate-x-[-50%] translate-y-[-50%] rounded-[6px] bg-white p-[25px] shadow-[hsl(206_22%_7%_/_35%)_0px_10px_38px_-10px,_hsl(206_22%_7%_/_20%)_0px_10px_20px_-15px] focus:outline-none"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Title&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"text-mauve12 m-0 text-[17px] font-medium"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          Are you absolutely sure?
        &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Title&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Description&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"text-mauve11 mt-4 mb-5 text-[15px] leading-normal"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          This action cannot be undone. This will permanently delete your account and remove your
          data from our servers.
        &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Description&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"flex justify-end gap-[25px]"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Cancel&lt;/span&gt; &lt;span class="na"&gt;asChild&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"text-mauve11 bg-mauve4 hover:bg-mauve5 focus:shadow-mauve7 inline-flex h-[35px] items-center justify-center rounded-[4px] px-[15px] font-medium leading-none outline-none focus:shadow-[0_0_0_2px]"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
              Cancel
            &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Cancel&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Action&lt;/span&gt; &lt;span class="na"&gt;asChild&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
            &lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt; &lt;span class="na"&gt;className&lt;/span&gt;&lt;span class="p"&gt;=&lt;/span&gt;&lt;span class="s"&gt;"text-red11 bg-red4 hover:bg-red5 focus:shadow-red7 inline-flex h-[35px] items-center justify-center rounded-[4px] px-[15px] font-medium leading-none outline-none focus:shadow-[0_0_0_2px]"&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
              Yes, delete account
            &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;button&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
          &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Action&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nt"&gt;div&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Content&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Portal&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="p"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="nc"&gt;AlertDialog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Root&lt;/span&gt;&lt;span class="p"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="k"&gt;default&lt;/span&gt; &lt;span class="nx"&gt;AlertDialogDemo&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Shadcn UI:&lt;/strong&gt; To set up Shadcn UI, you need to initialize a new shadcn project with yours, shadcn comes with a CLI that integrates with your favorite &lt;code&gt;frameworks&lt;/code&gt;, example are &lt;code&gt;Next.js&lt;/code&gt;, &lt;code&gt;Vite&lt;/code&gt;, &lt;code&gt;Remix&lt;/code&gt;, &lt;code&gt;Gatsby&lt;/code&gt;, &lt;code&gt;Astro&lt;/code&gt; etc. Pick your favorite framework and run the CLI&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Example using Next.js
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Create project:&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Start by creating a new Next.js project using &lt;code&gt;create-next-app&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pnpm create next-app@latest my-app &lt;span class="nt"&gt;--typescript&lt;/span&gt; &lt;span class="nt"&gt;--tailwind&lt;/span&gt; &lt;span class="nt"&gt;--eslint&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Run the CLI:&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Run the &lt;code&gt;shadcn-ui&lt;/code&gt; init command to setup your project:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pnpm dlx shadcn-ui@latest init
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Configure components.json:&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;You will be asked a few questions to configure &lt;code&gt;components.json&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Would you like to use TypeScript (recommended)? no / yes
Which style would you like to use? › Default
Which color would you like to use as base color? › Slate
Where is your global CSS file? › › app/globals.css
Do you want to use CSS variables for colors? › no / yes
Where is your tailwind.config.js located? › tailwind.config.js
Configure the import alias for components: › @/components
Configure the import alias for utils: › @/lib/utils
Are you using React Server Components? › no / yes
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;App structure:&lt;/strong&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;.
├── app
│   ├── layout.tsx
│   └── page.tsx
├── components
│   ├── ui
│   │   ├── alert-dialog.tsx
│   │   ├── button.tsx
│   │   ├── dropdown-menu.tsx
│   │   └── ...
│   ├── main-nav.tsx
│   ├── page-header.tsx
│   └── ...
├── lib
│   └── utils.ts
├── styles
│   └── globals.css
├── next.config.js
├── package.json
├── postcss.config.js
├── tailwind.config.js
└── tsconfig.json
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;&lt;p&gt;I place the UI components in the &lt;code&gt;components/ui&lt;/code&gt; folder.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The rest of the components such as &lt;code&gt;&amp;lt;PageHeader /&amp;gt;&lt;/code&gt; and &lt;code&gt;&amp;lt;MainNav /&amp;gt;&lt;/code&gt; are placed in the &lt;code&gt;components&lt;/code&gt; folder.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The &lt;code&gt;lib&lt;/code&gt; folder contains all the utility functions. I have a &lt;code&gt;utils.ts&lt;/code&gt; where I define the &lt;code&gt;cn&lt;/code&gt; helper.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The &lt;code&gt;styles&lt;/code&gt; folder contains the global CSS.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;That's it:&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;You can now start adding components to your project.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pnpm dlx shadcn-ui@latest add button
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;p&gt;The command above will add the &lt;code&gt;Button&lt;/code&gt; component to your project. You can then import it like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;import &lt;span class="o"&gt;{&lt;/span&gt; Button &lt;span class="o"&gt;}&lt;/span&gt; from &lt;span class="s2"&gt;"@/components/ui/button"&lt;/span&gt;

&lt;span class="nb"&gt;export &lt;/span&gt;default &lt;span class="k"&gt;function &lt;/span&gt;Home&lt;span class="o"&gt;()&lt;/span&gt; &lt;span class="o"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="o"&gt;(&lt;/span&gt;
    &amp;lt;div&amp;gt;
      &amp;lt;Button&amp;gt;Click me&amp;lt;/Button&amp;gt;
    &amp;lt;/div&amp;gt;
  &lt;span class="o"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Key Features
&lt;/h2&gt;

&lt;p&gt;Sure, here are the key features of Tailwind, Radix UI, and Shadcn UI:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Tailwind&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Highly customizable&lt;/li&gt;
&lt;li&gt;Can be used to create a wide variety of designs&lt;/li&gt;
&lt;li&gt;Easy to learn&lt;/li&gt;
&lt;li&gt;Can be used with any JavaScript framework&lt;/li&gt;
&lt;li&gt;Provides a wide range of utility classes&lt;/li&gt;
&lt;li&gt;Can be used to create custom components&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;strong&gt;Radix UI&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Ready-made components&lt;/li&gt;
&lt;li&gt;Easy to get started&lt;/li&gt;
&lt;li&gt;Provides a wide range of components&lt;/li&gt;
&lt;li&gt;Supports a variety of screen sizes&lt;/li&gt;
&lt;li&gt;Well-documented&lt;/li&gt;
&lt;li&gt;Actively maintained&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;strong&gt;Shadcn UI&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Combines the best features of Tailwind and Radix UI&lt;/li&gt;
&lt;li&gt;Highly customizable&lt;/li&gt;
&lt;li&gt;Provides a set of ready-made components&lt;/li&gt;
&lt;li&gt;Easy to learn&lt;/li&gt;
&lt;li&gt;Actively maintained&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;Here is a table that summarizes the key features of each CSS library:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Tailwind&lt;/th&gt;
&lt;th&gt;Highly customizable, can be used to create a wide variety of designs, easy to learn, can be used with any JavaScript framework, provides a wide range of utility classes, can be used to create custom components&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Radix UI&lt;/td&gt;
&lt;td&gt;Ready-made components, easy to get started, provides a wide range of components, supports a variety of screen sizes, well-documented, actively maintained&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Shadcn UI&lt;/td&gt;
&lt;td&gt;Combines the best features of Tailwind and Radix UI, highly customizable, provides a set of ready-made components, easy to learn, actively maintained&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  My recommendation
&lt;/h2&gt;

&lt;p&gt;Sure, here is a summary of the three CSS libraries, along with my recommendation for which is the easiest to set up and understand:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Tailwind&lt;/strong&gt; is the most customizable library, but it can also be the most difficult to learn and set up. It's a good choice for developers who want to have complete control over their CSS, but it may not be the best choice for beginners.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Radix UI&lt;/strong&gt; is the easiest library to set up and understand. It provides a set of ready-made components that you can use to build your web application, without having to write any custom CSS. However, Radix UI is not as customizable as Tailwind, so it may not be the best choice for developers who need a lot of control over their CSS.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Shadcn UI&lt;/strong&gt; is a good compromise between Tailwind and Radix UI. It's more customizable than Radix UI, but it's also easier to set up and understand than Tailwind. Shadcn UI is a good choice for developers who want a balance of customization and ease of use.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;My recommendation for the easiest library to set up and understand is Shadcn UI.&lt;/strong&gt; It's a good choice for developers of all levels, and it provides a good balance of customization and ease of use.&lt;/p&gt;

</description>
      <category>tailwindcss</category>
      <category>programming</category>
      <category>opensource</category>
      <category>css</category>
    </item>
    <item>
      <title>The Complete 2023 Developer Setup</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Sun, 06 Aug 2023 18:54:29 +0000</pubDate>
      <link>https://dev.to/timidev/the-complete-2023-developer-setup-2oia</link>
      <guid>https://dev.to/timidev/the-complete-2023-developer-setup-2oia</guid>
      <description>&lt;h2&gt;
  
  
  The Complete 2023 Developer Setup
&lt;/h2&gt;




&lt;ul&gt;
&lt;li&gt;Node.js&lt;/li&gt;
&lt;li&gt;Express.js&lt;/li&gt;
&lt;li&gt;TypeScript&lt;/li&gt;
&lt;li&gt;MongoDB&lt;/li&gt;
&lt;li&gt;React&lt;/li&gt;
&lt;li&gt;Docker&lt;/li&gt;
&lt;li&gt;PostgreSQL&lt;/li&gt;
&lt;li&gt;Tailwind CSS&lt;/li&gt;
&lt;li&gt;Git&lt;/li&gt;
&lt;li&gt;GitHub&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  1. Node.js
&lt;/h3&gt;

&lt;p&gt;Node.js is a fast and efficient runtime environment for JavaScript. It uses the V8 engine and offers non-blocking libraries.&lt;/p&gt;




&lt;h3&gt;
  
  
  2. Express.js
&lt;/h3&gt;

&lt;p&gt;Express is a popular Node web framework with functions like creating handlers for requests, integrating with rendering engines, adjusting application settings, and inserting middleware.&lt;/p&gt;




&lt;h3&gt;
  
  
  3. TypeScript
&lt;/h3&gt;

&lt;p&gt;TypeScript is an advanced version of JavaScript that includes additional features and introduces static typing to minimize errors.&lt;/p&gt;




&lt;h3&gt;
  
  
  4. MongoDB
&lt;/h3&gt;

&lt;p&gt;MongoDB is an open-source NoSQL database used for high-volume data storage, ad-hoc queries, indexing, load balancing, aggregation, and server-side JavaScript execution. It stores information in collections of documents made up of key-value pairs and supports many programming languages.&lt;/p&gt;




&lt;h3&gt;
  
  
  5. React.js
&lt;/h3&gt;

&lt;p&gt;React is a front-end JavaScript library that is free and open-source. It is used for building user interfaces by utilizing components.&lt;/p&gt;




&lt;h3&gt;
  
  
  6. Docker
&lt;/h3&gt;

&lt;p&gt;Docker simplifies application creation, testing, and release by packaging software into containers containing all necessary components for the code to run. This ensures correct code functionality upon deployment and expansion into any environment.&lt;/p&gt;




&lt;h3&gt;
  
  
  7. PostgreSQL
&lt;/h3&gt;

&lt;p&gt;PostgreSQL is an open-source relational database that allows querying in SQL and JSON. It’s been developed for over 20 years, making it a stable and reliable system used by many applications.&lt;/p&gt;




&lt;h3&gt;
  
  
  8. Tailwind CSS
&lt;/h3&gt;

&lt;p&gt;Tailwind CSS is a utility-first CSS framework for quick UI development with flexible building blocks and no stubborn pre-set styles.&lt;/p&gt;




&lt;h3&gt;
  
  
  9. Git
&lt;/h3&gt;

&lt;p&gt;Developers use Git to monitor changes made to their code over time.&lt;/p&gt;




&lt;h3&gt;
  
  
  10. GitHub
&lt;/h3&gt;

&lt;p&gt;GitHub offers hosting services for Git repositories, enabling collaboration on projects, and providing tools for project management, issue tracking, and code review. Git and GitHub are crucial for software development and collaboration.&lt;/p&gt;

</description>
      <category>community</category>
      <category>javascript</category>
      <category>programming</category>
      <category>frontend</category>
    </item>
    <item>
      <title>Use Type, not Interface in TypeScript</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Sat, 05 Aug 2023 14:57:28 +0000</pubDate>
      <link>https://dev.to/timidev/use-type-not-interface-in-typescript-34i7</link>
      <guid>https://dev.to/timidev/use-type-not-interface-in-typescript-34i7</guid>
      <description>&lt;p&gt;As we delve into the fascinating world of TypeScript, it becomes apparent that understanding and leveraging the nuances of type usage is pivotal to writing efficient and robust code. Today, we'll explore the critical distinction between using &lt;strong&gt;Type&lt;/strong&gt; and &lt;strong&gt;Interface&lt;/strong&gt; in TypeScript, and how this understanding can significantly impact the overall performance and maintainability of your projects.&lt;/p&gt;

&lt;h2&gt;
  
  
  TypeScript: A Brief Overview
&lt;/h2&gt;

&lt;p&gt;Before we embark on our exploration of &lt;strong&gt;Type&lt;/strong&gt; and &lt;strong&gt;Interface&lt;/strong&gt; in TypeScript, let's take a moment to understand what TypeScript is and why it has become such a popular choice among developers.&lt;/p&gt;

&lt;p&gt;TypeScript, developed by Microsoft, is a superset of JavaScript that introduces static typing capabilities. It allows developers to write strongly-typed code, catching errors at compile-time rather than runtime. This feature enhances code readability, maintainability, and overall productivity. As TypeScript transpiles into plain JavaScript, it can be effortlessly integrated into any existing JavaScript project.&lt;/p&gt;

&lt;h2&gt;
  
  
  Understanding Type and Interface
&lt;/h2&gt;

&lt;p&gt;In TypeScript, both &lt;strong&gt;Type&lt;/strong&gt; and &lt;strong&gt;Interface&lt;/strong&gt; are used to define custom data types, but they serve distinct purposes. Let's look at each of them individually.&lt;/p&gt;

&lt;h2&gt;
  
  
  Type: Defining Unions, Intersections, and Aliases
&lt;/h2&gt;

&lt;p&gt;With &lt;strong&gt;Type&lt;/strong&gt;, we have the flexibility to create aliases for existing types, define unions or intersections of types, and even create complex data structures. It is particularly useful when dealing with scenarios that require combining multiple types or reusing them in various parts of the codebase.&lt;/p&gt;

&lt;p&gt;Let's take an example to illustrate the power of &lt;strong&gt;Type&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;type&lt;/span&gt; &lt;span class="nx"&gt;Pet&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;age&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;number&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="kd"&gt;type&lt;/span&gt; &lt;span class="nx"&gt;Dog&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;Pet&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;breed&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="kd"&gt;type&lt;/span&gt; &lt;span class="nx"&gt;Cat&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;Pet&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;};&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;printPetInfo&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pet&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;Pet&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`Name: &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;pet&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;, Age: &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;pet&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;age&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;printDogInfo&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;dog&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;Dog&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`Name: &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;dog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;name&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;, Age: &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;dog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;age&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;, Breed: &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;dog&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;breed&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the above example, we define a &lt;strong&gt;Pet&lt;/strong&gt; type and then create two additional types, &lt;strong&gt;Dog&lt;/strong&gt; and &lt;strong&gt;Cat&lt;/strong&gt;, by combining it with additional properties specific to each. This makes our code more organized, maintainable, and less prone to errors.&lt;/p&gt;

&lt;h2&gt;
  
  
  Interface: Extending Objects and Classes
&lt;/h2&gt;

&lt;p&gt;On the other hand, &lt;strong&gt;Interface&lt;/strong&gt; in TypeScript is primarily used for extending object shapes and classes. It allows us to specify the structure that an object must adhere to, providing a clear contract for the code.&lt;/p&gt;

&lt;p&gt;Let's demonstrate the use of &lt;strong&gt;Interface&lt;/strong&gt; with an example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kr"&gt;interface&lt;/span&gt; &lt;span class="nx"&gt;Shape&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nf"&gt;area&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt; &lt;span class="kr"&gt;number&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="kd"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;Circle&lt;/span&gt; &lt;span class="k"&gt;implements&lt;/span&gt; &lt;span class="nx"&gt;Shape&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nf"&gt;constructor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;public&lt;/span&gt; &lt;span class="nx"&gt;radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;number&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{}&lt;/span&gt;

    &lt;span class="nx"&gt;name&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Circle&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

    &lt;span class="nf"&gt;area&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;PI&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;radius&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;radius&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In this example, we define an &lt;strong&gt;Interface&lt;/strong&gt; called &lt;strong&gt;Shape&lt;/strong&gt; that mandates an object to have a name property and an area method. Then, we implement this Shape interface in a Circle class, ensuring that the Circle class adheres to the specified structure.&lt;/p&gt;

&lt;h2&gt;
  
  
  Best Practices: When to Use Type and Interface
&lt;/h2&gt;

&lt;p&gt;Now that we comprehend the differences between &lt;strong&gt;Type&lt;/strong&gt; and &lt;strong&gt;Interface&lt;/strong&gt;, it's essential to understand when to use each of them to write more maintainable and performant code.&lt;/p&gt;

&lt;h3&gt;
  
  
  Use Type When:
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;You need to create a union or intersection of multiple types.&lt;/li&gt;
&lt;li&gt;You want to create aliases for complex types to improve code readability.&lt;/li&gt;
&lt;li&gt;You are dealing with scenarios that require reusing types across the project.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Use Interface When:
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;You want to specify the structure that an object must adhere to.&lt;/li&gt;
&lt;li&gt;You need to extend an object shape or class to ensure it adheres to a contract.&lt;/li&gt;
&lt;li&gt;You are defining the shape of an object that will be used by multiple classes or functions.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  TypeScript's Type Inference: The Best of Both Worlds
&lt;/h2&gt;

&lt;p&gt;One of the fantastic features of TypeScript is its powerful type inference mechanism. TypeScript can automatically infer the type of variables and expressions, reducing the need for explicit type annotations in most cases.&lt;/p&gt;

&lt;p&gt;This brings the best of both &lt;strong&gt;Type&lt;/strong&gt; and &lt;strong&gt;Interface&lt;/strong&gt; worlds. When TypeScript can infer types correctly, you can rely on the concise and clean code without explicitly specifying types. However, in more complex scenarios, you can always fall back on &lt;strong&gt;Type&lt;/strong&gt; and &lt;strong&gt;Interface&lt;/strong&gt; to provide explicit type definitions.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;In conclusion, TypeScript is a powerful language that empowers developers to write safer and more maintainable code by leveraging static typing. Understanding the appropriate usage of &lt;strong&gt;Type&lt;/strong&gt; and &lt;strong&gt;Interface&lt;/strong&gt; is essential in harnessing the full potential of TypeScript.&lt;/p&gt;

&lt;p&gt;Remember, using &lt;strong&gt;Type&lt;/strong&gt; is ideal when dealing with unions, intersections, and type aliases, while &lt;strong&gt;Interface&lt;/strong&gt; excels at defining object shapes and class contracts. By applying these best practices, you can ensure that your TypeScript projects are not only efficient but also outrank others in search engine results.&lt;/p&gt;

</description>
      <category>typescript</category>
      <category>opensource</category>
      <category>node</category>
      <category>react</category>
    </item>
    <item>
      <title>How to Secure Your MongoDB Database Against Attack</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Sun, 25 Jun 2023 18:32:46 +0000</pubDate>
      <link>https://dev.to/timidev/how-to-secure-your-mongodb-database-against-attack-12f8</link>
      <guid>https://dev.to/timidev/how-to-secure-your-mongodb-database-against-attack-12f8</guid>
      <description>&lt;p&gt;MongoDB is a popular NoSQL database that is used by a wide range of organizations. However, MongoDB can also be a target for attackers. In this blog post, we will discuss some best practices for securing your MongoDB database against attack.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Enable authentication and authorization&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The first step to securing your MongoDB database is to enable authentication and authorization. This will prevent unauthorized users from accessing your data. You can use the built-in SCRAM-SHA authentication mechanism or an external authentication system, such as LDAP or Active Directory.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Encrypt data at rest&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Even if you have enabled authentication and authorization, your data is still vulnerable if it is not encrypted at rest. This means that your data will be protected even if an attacker gains access to your database files. You can encrypt your data using the built-in encryption features in MongoDB or a third-party encryption solution.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Encrypt network traffic&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;In addition to encrypting data at rest, you should also encrypt network traffic to and from your MongoDB database. This will protect your data from being intercepted by attackers while it is in transit. You can use the built-in TLS/SSL encryption features in MongoDB or a third-party encryption solution.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. Use role-based access control (RBAC)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Once you have enabled authentication and authorization, you can use RBAC to control who has access to different parts of your database. This will help you to limit the damage that an attacker can cause if they do gain access to your database.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5. Monitor your database for suspicious activity&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It is important to monitor your database for suspicious activity. This will help you to detect any unauthorized access or changes to your data. You can use the built-in auditing features in MongoDB or a third-party monitoring solution.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;6. Keep your database up to date&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;MongoDB releases security updates on a regular basis. It is important to keep your database up to date with the latest security patches. This will help to protect your database from known vulnerabilities.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;By following these best practices, you can help to secure your MongoDB database against attack. However, it is important to remember that no security measure is perfect. You should also implement other security measures, such as a firewall and intrusion detection system, to protect your entire network.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Additional resources:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;MongoDB Security Checklist: &lt;a href="https://www.mongodb.com/docs/manual/administration/security-checklist/"&gt;https://www.mongodb.com/docs/manual/administration/security-checklist/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;MongoDB Security Best Practices: &lt;a href="https://www.comparitech.com/net-admin/secure-mongodb/"&gt;https://www.comparitech.com/net-admin/secure-mongodb/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;How to Secure MongoDB: &lt;a href="https://www.mongodb.com/blog/post/hack-common-security-issues-fix-them"&gt;https://www.mongodb.com/blog/post/hack-common-security-issues-fix-them&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>database</category>
      <category>security</category>
      <category>discuss</category>
      <category>mongodb</category>
    </item>
    <item>
      <title>Secure your Nodejs REST API By using Rate Limiting</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Sat, 24 Jun 2023 14:46:55 +0000</pubDate>
      <link>https://dev.to/timidev/rate-limiting-in-nodejs-and-express-56pj</link>
      <guid>https://dev.to/timidev/rate-limiting-in-nodejs-and-express-56pj</guid>
      <description>&lt;p&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Rate limiting is a technique used to control the number of requests that a client can make to an API within a given period of time. This can be used to protect your API from being overloaded by malicious traffic or to prevent individual users from making too many requests and impacting the performance of your API for other users.&lt;/p&gt;

&lt;p&gt;In this blog post, we will show you how to implement rate limiting in your Node.js API using the Express framework. We will use the &lt;code&gt;express-rate-limit&lt;/code&gt; package to do this, which is a popular and well-maintained library for rate limiting in Node.js.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Prerequisites&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Before you start, you will need to have the following installed:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Node.js&lt;/li&gt;
&lt;li&gt;The Express framework&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;express-rate-limit&lt;/code&gt; package&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Setting up the rate limiter&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The first step is to install the &lt;code&gt;express-rate-limit&lt;/code&gt; package. You can do this by running the following command in your terminal:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Code snippet&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install &lt;/span&gt;express-rate-limit
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once you have installed the package, you can create a new Express application. In your application's main file, you will need to require the &lt;code&gt;express-rate-limit&lt;/code&gt; package and create a new rate limiter instance. The following code shows how to do this:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Code snippet&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;express&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;express&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;rateLimit&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;require&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;express-rate-limit&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;app&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;express&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;limiter&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;rateLimit&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;max&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;windowMs&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;max&lt;/code&gt; property specifies the maximum number of requests that a client can make within the specified window of time. The &lt;code&gt;windowMs&lt;/code&gt; property specifies the length of the window in milliseconds.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Applying the rate limiter&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Once you have created a rate limiter instance, you can apply it to your Express routes. To do this, you can use the &lt;code&gt;use()&lt;/code&gt; method. The following code shows how to apply the rate limiter to a route that returns a list of users:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Code snippet&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight tsx"&gt;&lt;code&gt;&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/users&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;limiter&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;req&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;res&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="c1"&gt;// Get a list of users&lt;/span&gt;
  &lt;span class="nx"&gt;res&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;send&lt;/span&gt;&lt;span class="p"&gt;([&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;John Doe&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Jane Doe&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When a client makes a request to this route, the rate limiter will check to see if the client has exceeded the maximum number of requests for the current window. If the client has exceeded the limit, the rate limiter will return an error response.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Testing the rate limiter&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You can test the rate limiter by making a number of requests to the &lt;code&gt;/users&lt;/code&gt; route. If you make more than 10 requests within a 60-second window, you will start to receive error responses from the rate limiter.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusion&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;In this blog post, we have shown you how to implement rate limiting in your Node.js API using the Express framework. We used the &lt;code&gt;express-rate-limit&lt;/code&gt; package to do this, which is a popular and well-maintained library for rate limiting in Node.js.&lt;/p&gt;

&lt;p&gt;I hope this blog post was helpful. If you have any questions, please feel free to leave a comment below.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>api</category>
      <category>programming</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Are you even full stack ready?</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Sat, 03 Jun 2023 18:00:00 +0000</pubDate>
      <link>https://dev.to/timidev/are-you-even-full-stack-ready-21np</link>
      <guid>https://dev.to/timidev/are-you-even-full-stack-ready-21np</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Are you ready to be a full-stack developer? Is "full-stack" even a real concept? And most importantly, do you have the skills to become one? Let's cut out the ridiculousness and see if you're really ready to be a full-stack developer. &lt;/p&gt;

&lt;p&gt;Hey, I'm Timi, a full-stack web developer, and I love sharing my knowledge with young developers on Twitter. Today, we're going to determine whether you're ready to become a full-stack developer.&lt;/p&gt;

&lt;h2&gt;
  
  
  What even is Full Stack
&lt;/h2&gt;

&lt;p&gt;In simpler terms, a full-stack developer is someone who has the knowledge and skills to build and handle all the different parts of a website, making it work smoothly and look good to the users. They're like the all-in-one problem solvers of the web development world!&lt;/p&gt;

&lt;h2&gt;
  
  
  What even is Full Stack #2
&lt;/h2&gt;

&lt;p&gt;So, a full stack developer is like a handy person who can handle everything from the back-end to the front-end of a website. They are comfortable with coding the server-side (the back-end) which involves working with databases, servers, and programming languages like Python or Java. At the same time, they can also handle the client-side (the front-end) which includes creating the user interface, designing layouts, and writing code in HTML, CSS, and JavaScript.&lt;/p&gt;

&lt;h2&gt;
  
  
  Digging deeper
&lt;/h2&gt;

&lt;p&gt;To become a full stack developer, you need to know more than just the frontend and the backend.&lt;/p&gt;

&lt;h2&gt;
  
  
  Ranting
&lt;/h2&gt;

&lt;p&gt;You might have watched a video covering what a full stack dev is. But I want to tell you all something: most of these guys don't really know what they're doing. Now, I don't want to say all YouTubers don't know what they're doing, but I'm just saying some courses on Full Stack don't really teach what a full stack dev is, or even scratch the surface.&lt;/p&gt;

&lt;h2&gt;
  
  
  Can anyone become a Full-Stack Developer
&lt;/h2&gt;

&lt;p&gt;Yes and no. Before I explain further, I have a few questions for you. If you can answer them correctly, we will determine if you're ready for Full-Stack development.&lt;/p&gt;

&lt;h3&gt;
  
  
  Questions
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Why do you wanna go full-stack&lt;/li&gt;
&lt;li&gt;Why did you started this journey “programming”&lt;/li&gt;
&lt;li&gt;Are you willing to take in that tough road&lt;/li&gt;
&lt;li&gt;Are you a good problem solver&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now, the reasons I said "yes" and "no" to my previous question were because I don't really think full-stack development is for everyone, or programming in general. You don't pursue this field just because you have a passion for it. Passion is good, believe me, but I don't think you'll need more of it than you'll need discipline. You have to be disciplined, show up every day, and have the urge to build things and solve problems.&lt;/p&gt;

&lt;h2&gt;
  
  
  Here's an outline of the traits of a good Full-Stack Developer:
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Strong problem-solving skills&lt;/li&gt;
&lt;li&gt;Comfortable with both front-end and back-end development&lt;/li&gt;
&lt;li&gt;Ability to learn and adapt quickly&lt;/li&gt;
&lt;li&gt;Effective communication skills&lt;/li&gt;
&lt;li&gt;Attention to detail&lt;/li&gt;
&lt;li&gt;Understanding of security concerns and best practices&lt;/li&gt;
&lt;li&gt;Familiarity with multiple programming languages and frameworks&lt;/li&gt;
&lt;li&gt;Creativity and a desire to innovate&lt;/li&gt;
&lt;li&gt;Passion for building things and solving problems&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Let me elaborate on each of these traits:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Strong problem-solving skills&lt;/strong&gt;: Full-Stack Developers need to be able to identify and resolve issues that occur throughout the development process. They should be able to analyze a problem, come up with multiple potential solutions, and choose the best one.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Comfortable with both front-end and back-end development&lt;/strong&gt;: Full-Stack Developers must be proficient in both front-end and back-end development, including languages like HTML, CSS, JavaScript, Python, and Java. They must also be familiar with databases, servers, and other infrastructure components.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ability to learn and adapt quickly&lt;/strong&gt;: The tech industry is constantly evolving, and Full-Stack Developers must keep up with the latest trends and technologies. They must be able to learn new programming languages, frameworks, and tools quickly and adapt to changing circumstances.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Effective communication skills&lt;/strong&gt;: Full-Stack Developers often work in teams, so strong communication skills are crucial. They need to be able to collaborate effectively with other developers, designers, and stakeholders and clearly communicate their ideas and solutions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Attention to detail&lt;/strong&gt;: Full-Stack Developers need to pay close attention to detail to ensure that their code is free of errors and runs smoothly. They must also be able to spot potential security vulnerabilities and design flaws.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Understanding of security concerns and best practices&lt;/strong&gt;: Full-Stack Developers must be aware of the latest security concerns and best practices and take steps to ensure that their code is secure and protected from potential threats.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Familiarity with multiple programming languages and frameworks&lt;/strong&gt;: Full-Stack Developers should be familiar with a variety of programming languages and frameworks, including those used in both front-end and back-end development.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Creativity and a desire to innovate&lt;/strong&gt;: Full-Stack Developers should be creative problem-solvers who are always looking for new and innovative ways to build and improve web applications.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Passion for building things and solving problems&lt;/strong&gt;: Finally, Full-Stack Developers should have a genuine passion for building things and solving problems. They should be excited about the prospect of using their skills to create useful, engaging, and impactful web applications.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;These are just a few of the traits of a good Full-Stack Developer. By developing these skills and characteristics, you can become a valuable asset to any web development team.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;I think it's time to close this. It's been fun. I hope you all can learn something from this. Becoming a full-stack developer is a journey, not a race. It's a journey that requires your daily attention and dedication.&lt;/p&gt;

&lt;p&gt;So, back to my question: are you full-stack ready?&lt;/p&gt;

</description>
      <category>fullstack</category>
      <category>javascript</category>
      <category>programming</category>
    </item>
    <item>
      <title>Semantic versioning explained like you are 5</title>
      <dc:creator>Timi</dc:creator>
      <pubDate>Fri, 02 Jun 2023 18:10:09 +0000</pubDate>
      <link>https://dev.to/timidev/semantic-versioning-explained-like-you-are-5-1k3d</link>
      <guid>https://dev.to/timidev/semantic-versioning-explained-like-you-are-5-1k3d</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Hey, I'm Timi, a Full Stack Web Developer, and I love sharing my knowledge with young developers on Twitter. Today, we're diving into the fascinating world of semantic versioning. Buckle up because we're about to explore its depths, going deeper than the ocean itself. So, let's get started!&lt;/p&gt;

&lt;h3&gt;
  
  
  What is Semantic Versioning?
&lt;/h3&gt;

&lt;p&gt;To put it simply, semantic versioning is a way of numbering software releases to convey meaningful information about changes made to the codebase. It follows a three-part versioning scheme: Major.Minor.Patch. Each number represents a specific aspect of the update:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Major: Incremented when incompatible changes are introduced, indicating potential breaking changes that may require adjustments to existing code.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Minor: Indicates the addition of new features in a backward-compatible manner. It signifies improvements and enhancements to the software.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Patch: Represents bug fixes, security patches, or other minor updates that don't introduce new features or change existing functionality.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Why is Semantic Versioning Important?
&lt;/h3&gt;

&lt;p&gt;Semantic versioning brings order and clarity to the chaotic world of software updates. By adhering to a standardized versioning scheme, developers can effectively communicate the impact of changes to other developers and end-users. Here are a few reasons why semantic versioning is crucial:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;Compatibility: Version numbers provide a clear indication of backward compatibility. By analyzing the version number, developers can quickly determine if an update will require modifications to their code or if it can be safely integrated into existing systems.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Predictability: Semantic versioning enables developers to set realistic expectations for their users. When users see a new version with a minor increment, they know it brings new features without breaking their current workflow. On the other hand, a major version increment implies potential challenges and the need for careful consideration before upgrading.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Dependency Management: In the vast ecosystem of software development, projects often rely on external libraries and frameworks. Semantic versioning helps manage these dependencies efficiently. By specifying version ranges, developers can ensure that their project works with compatible versions of the dependencies while avoiding incompatible or unstable releases.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Communication: Semantic versioning encourages effective communication within the development community. Developers can understand the scope and impact of changes made by other developers by simply looking at the version number. This shared understanding leads to smoother collaborations and more informed decision-making.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Conclusion:
&lt;/h3&gt;

&lt;p&gt;Semantic versioning is the compass that guides developers and end-users through the intricate landscape of software updates. It brings clarity, predictability, and order to the ever-evolving world of technology. By understanding and embracing semantic versioning, developers can build robust and reliable software systems while allowing users to make informed decisions about when and how to update. So the next time you see a software update, take a moment to appreciate the power of semantic versioning, silently working behind the scenes to make our digital experiences better.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>tutorial</category>
      <category>discuss</category>
    </item>
  </channel>
</rss>
